Skip to content

Commit 8ae8ceb

Browse files
committed
feat(lago-rails): make Puma concurrency and thread config optional
Add conditional environment variables for WEB_CONCURRENCY, RAILS_MAX_THREADS, and RAILS_MIN_THREADS in the deployment template so they are only set when explicitly configured. Remove the hardcoded default of 4 for concurrency in values.yaml, allowing Puma to use its own defaults when no value is provided.
1 parent dd4924e commit 8ae8ceb

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

charts/lago-rails/templates/deployment.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,18 @@ spec:
6363
value: {{ .Values.config.web.sidekiq | quote }}
6464
- name: LAGO_DISABLE_SIGNUP
6565
value: {{ not .Values.global.lago.signup | quote }}
66+
{{- with .Values.config.web.concurrency }}
67+
- name: WEB_CONCURRENCY
68+
value: {{ . }}
69+
{{- end }}
70+
{{- with .Values.config.web.maxThreads }}
71+
- name: RAILS_MAX_THREADS
72+
value: {{ . }}
73+
{{- end }}
74+
{{- with .Values.config.web.minThreads }}
75+
- name: RAILS_MIN_THREADS
76+
value: {{ . }}
77+
{{- end }}
6678
- name: DATABASE_URL
6779
valueFrom:
6880
secretKeyRef:

charts/lago-rails/values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ config:
149149
web:
150150
maxThreads:
151151
minThreads:
152-
concurrency: 4
152+
concurrency:
153153
sidekiq: false
154154

155155
sidekiq:

0 commit comments

Comments
 (0)