From 05b56dbc9693ff891fb92b4e3c4fee1aff6b05ce Mon Sep 17 00:00:00 2001 From: Dmitrii Sashchenko Date: Thu, 26 Mar 2026 09:15:29 +0000 Subject: [PATCH 1/3] =?UTF-8?q?=D0=B1=D0=B0=D0=B7=D0=BE=D0=B2=D1=8B=D0=B9?= =?UTF-8?q?=20=D0=BA=D0=BB=D0=B0=D1=81=D1=82=D0=B5=D1=80=20k8s=20=D0=B8=20?= =?UTF-8?q?dragonfly=20maxmemory?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .helm/templates/02-dragonfly.yaml | 2 ++ .helm/templates/02-nats-box.yaml | 2 +- .helm/values.yaml | 6 +++++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.helm/templates/02-dragonfly.yaml b/.helm/templates/02-dragonfly.yaml index 46bb085..002a7d4 100644 --- a/.helm/templates/02-dragonfly.yaml +++ b/.helm/templates/02-dragonfly.yaml @@ -21,6 +21,8 @@ spec: containers: - name: dragonfly image: cr.yandex/crpnn6fi85p3dauha6nc/dragonflydb:1.15.1 + args: + - --maxmemory={{ .Values.dragonfly.maxmemory | default "256M" }} ports: - name: dragonfly containerPort: 6379 diff --git a/.helm/templates/02-nats-box.yaml b/.helm/templates/02-nats-box.yaml index c5b25d1..a3c815c 100644 --- a/.helm/templates/02-nats-box.yaml +++ b/.helm/templates/02-nats-box.yaml @@ -58,7 +58,7 @@ spec: fieldRef: fieldPath: metadata.namespace - name: CLUSTER_ADVERTISE - value: $(POD_NAME).{{ .Chart.Name }}-nats.$(POD_NAMESPACE).svc.cluster.local + value: $(POD_NAME).{{ .Chart.Name }}-nats.$(POD_NAMESPACE).{{ .Values.cluster.domain | default "cluster.local" }}.local volumeMounts: - name: config-volume mountPath: /etc/nats-config diff --git a/.helm/values.yaml b/.helm/values.yaml index bd845cc..58b1ed4 100644 --- a/.helm/values.yaml +++ b/.helm/values.yaml @@ -288,6 +288,9 @@ ingress: # Или используйте cert-manager для автоматического получения сертификатов secretName: "hrbox-tls" +cluster: + domain: "cluster.local" # Укажите домен текущего k8s-кластера, если используется нестандартный + # Настройки ресурсов для контейнеров # Указаны рекомендуемые значения для production resources: @@ -447,4 +450,5 @@ nats: dragonfly: # Включает или отключает развёртывание Dragonfly (Redis). # Установите в true, чтобы активировать, или в false, чтобы отключить. - enabled: true \ No newline at end of file + enabled: true + maxmemory: "256M" \ No newline at end of file From 2e4a8b4506d215af1b95f9361de206d1433e85b0 Mon Sep 17 00:00:00 2001 From: Dmitrii Sashchenko Date: Thu, 26 Mar 2026 09:58:06 +0000 Subject: [PATCH 2/3] no maxmemory by default --- .helm/templates/02-dragonfly.yaml | 4 +++- .helm/values.yaml | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.helm/templates/02-dragonfly.yaml b/.helm/templates/02-dragonfly.yaml index 002a7d4..920f4a6 100644 --- a/.helm/templates/02-dragonfly.yaml +++ b/.helm/templates/02-dragonfly.yaml @@ -21,8 +21,10 @@ spec: containers: - name: dragonfly image: cr.yandex/crpnn6fi85p3dauha6nc/dragonflydb:1.15.1 + {{- if .Values.dragonfly.maxmemory }} args: - - --maxmemory={{ .Values.dragonfly.maxmemory | default "256M" }} + - --maxmemory={{ .Values.dragonfly.maxmemory }} + {{- end }} ports: - name: dragonfly containerPort: 6379 diff --git a/.helm/values.yaml b/.helm/values.yaml index 58b1ed4..7417d95 100644 --- a/.helm/values.yaml +++ b/.helm/values.yaml @@ -451,4 +451,5 @@ dragonfly: # Включает или отключает развёртывание Dragonfly (Redis). # Установите в true, чтобы активировать, или в false, чтобы отключить. enabled: true - maxmemory: "256M" \ No newline at end of file + # По умолчанию параметр не используется. По необходимости, раскомментируйте и установите требуемое значение maxmemory + # maxmemory: "256M" \ No newline at end of file From 0a99bbdf563d7026f5c4f9cb453c3e1102d56da3 Mon Sep 17 00:00:00 2001 From: Dmitrii Sashchenko Date: Thu, 26 Mar 2026 10:07:47 +0000 Subject: [PATCH 3/3] =?UTF-8?q?=D0=BE=D0=BF=D0=B5=D1=87=D0=B0=D1=82=D0=BA?= =?UTF-8?q?=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .helm/templates/02-nats-box.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.helm/templates/02-nats-box.yaml b/.helm/templates/02-nats-box.yaml index a3c815c..4ff7e03 100644 --- a/.helm/templates/02-nats-box.yaml +++ b/.helm/templates/02-nats-box.yaml @@ -58,7 +58,7 @@ spec: fieldRef: fieldPath: metadata.namespace - name: CLUSTER_ADVERTISE - value: $(POD_NAME).{{ .Chart.Name }}-nats.$(POD_NAMESPACE).{{ .Values.cluster.domain | default "cluster.local" }}.local + value: $(POD_NAME).{{ .Chart.Name }}-nats.$(POD_NAMESPACE).{{ .Values.cluster.domain | default "cluster.local" }} volumeMounts: - name: config-volume mountPath: /etc/nats-config