Skip to content

Commit e52ae2b

Browse files
committed
feat(lago): add worker-arm64 subchart for the Graviton pilot
INF-375 needs a Sidekiq worker running on arm64 nodes, side by side with the existing amd64 worker, for an hours-scale comparison before scaling up. A single Deployment can't split its replicas across two node architectures, so this adds a second one. worker-arm64 is a new lago-rails alias gated by global.arm64.enabled (default false), so bumping this chart's version is a no-op on any cluster without an arm64 nodepool. Its values merge worker's defaults through a YAML anchor and override only what differs: release name, replicaCount: 1, and the nodeSelector/toleration that pin it to the arm64 Karpenter nodepool added in lago-infrastructure PR #1595. Chart.lock was regenerated via `helm dependency update`. Chart versions are not bumped here — release.sh's workflow_dispatch step bumps every Chart.yaml automatically when the release is cut.
1 parent 2c9ebb0 commit e52ae2b

4 files changed

Lines changed: 126 additions & 3 deletions

File tree

charts/lago/Chart.lock

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@ dependencies:
2929
- name: lago-rails
3030
repository: file://../lago-rails
3131
version: 0.10.0
32+
- name: lago-rails
33+
repository: file://../lago-rails
34+
version: 0.10.0
3235
- name: lago-pdf
3336
repository: file://../lago-pdf
3437
version: 0.10.0
@@ -56,5 +59,5 @@ dependencies:
5659
- name: lago-rails
5760
repository: file://../lago-rails
5861
version: 0.10.0
59-
digest: sha256:d7709d8e8de47577d030c94a01339805506c63d203d77e120db89b91489b49e2
60-
generated: "2026-08-13T08:47:33.990668342Z"
62+
digest: sha256:362f12a2020ca3b60c2bd832de536c7861547b9b81c88aa6a180ded49b80cd12
63+
generated: "2026-08-26T16:29:47.163824755+03:00"

charts/lago/Chart.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ dependencies:
3535
alias: worker
3636
version: 0.10.0
3737
repository: "file://../lago-rails"
38+
- name: lago-rails
39+
alias: worker-arm64
40+
version: 0.10.0
41+
repository: "file://../lago-rails"
42+
condition: global.arm64.enabled
3843
- name: lago-rails
3944
alias: clock
4045
version: 0.10.0
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
suite: Test worker-arm64 subchart mirrors worker's shape via the shared YAML
2+
anchor and only differs in scheduling (nodeSelector/tolerations/replicas).
3+
global.arm64.enabled gates the subchart at the dependency level (verified
4+
manually via `helm template` with the flag unset — a disabled conditional
5+
dependency isn't selectable as a test template).
6+
templates:
7+
- charts/worker/templates/deployment.yaml
8+
- charts/worker-arm64/templates/deployment.yaml
9+
10+
set:
11+
global:
12+
lago:
13+
env: production
14+
version: v1.0.0
15+
urls:
16+
api: http://api.test
17+
front: http://front.test
18+
database:
19+
uri: postgresql://localhost
20+
encryption:
21+
key: test-key
22+
salt: test-salt
23+
signing:
24+
hmac: test-hmac
25+
rsa: test-rsa
26+
redis:
27+
uri: redis://localhost
28+
redisCache:
29+
uri: redis://localhost
30+
redisStore:
31+
uri: redis://localhost
32+
arm64:
33+
enabled: true
34+
35+
tests:
36+
- it: renders worker-arm64 with the same start script as worker
37+
template: charts/worker-arm64/templates/deployment.yaml
38+
asserts:
39+
- equal:
40+
path: metadata.name
41+
value: RELEASE-NAME-lago-worker-arm64
42+
- equal:
43+
path: spec.template.spec.containers[0].command
44+
value: ["./scripts/start.worker.sh"]
45+
- equal:
46+
path: spec.replicas
47+
value: 1
48+
49+
- it: pins worker-arm64 to arm64 nodes via nodeSelector and a matching toleration
50+
template: charts/worker-arm64/templates/deployment.yaml
51+
asserts:
52+
- equal:
53+
path: spec.template.spec.nodeSelector
54+
value:
55+
arch: arm64
56+
- contains:
57+
path: spec.template.spec.tolerations
58+
content:
59+
key: arch
60+
operator: Equal
61+
value: arm64
62+
effect: NoSchedule
63+
64+
- it: leaves worker unaffected — same command, no arm64 scheduling fields
65+
template: charts/worker/templates/deployment.yaml
66+
asserts:
67+
- equal:
68+
path: metadata.name
69+
value: RELEASE-NAME-lago-worker
70+
- equal:
71+
path: spec.template.spec.containers[0].command
72+
value: ["./scripts/start.worker.sh"]
73+
- notExists:
74+
path: spec.template.spec.nodeSelector
75+
- notExists:
76+
path: spec.template.spec.tolerations

charts/lago/values.yaml

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,16 @@ global:
2222
# @section -- Lago
2323
pdfGeneration: false
2424

25+
# -- arm64 (Graviton) migration pilot. Gates the `worker-arm64` subchart —
26+
# a second copy of the default Sidekiq worker, pinned to arm64 nodes via
27+
# its own nodeSelector/tolerations, run side-by-side with `worker` for
28+
# comparison. Off by default so bumping this chart's version is a no-op on
29+
# any cluster without an arm64 nodepool (the pod would otherwise sit
30+
# Pending forever with no schedulable node).
31+
# @section -- Arm64 Pilot
32+
arm64:
33+
enabled: false
34+
2535
sidekiq:
2636
# -- Enable Sidekiq Pro (requires valid license)
2737
# @section -- Sidekiq
@@ -443,7 +453,7 @@ front:
443453
# -- Default Sidekiq worker subchart overrides (lago-rails)
444454
# @default -- See child values
445455
# @section -- Default Worker
446-
worker:
456+
worker: &workerDefaults
447457
# -- Override the worker subchart release name
448458
# @section -- Default Worker
449459
nameOverride: lago-worker
@@ -477,6 +487,35 @@ worker:
477487
# @section -- Default Worker
478488
ports: []
479489

490+
# -- arm64 pilot subchart overrides (lago-rails, conditional on
491+
# `global.arm64.enabled`). Same queue/command as `worker` — a second,
492+
# separate Deployment pinned to arm64 nodes for side-by-side comparison, not
493+
# a new queue type — so it merges `worker`'s defaults via YAML anchor
494+
# instead of repeating them, and only overrides what actually differs:
495+
# release name, replica count, and scheduling.
496+
# @default -- See child values
497+
# @section -- Arm64 Pilot Worker
498+
worker-arm64:
499+
<<: *workerDefaults
500+
# -- Override the worker-arm64 subchart release name
501+
# @section -- Arm64 Pilot Worker
502+
nameOverride: lago-worker-arm64
503+
# -- Single replica for the pilot — scaled up manually once the baseline
504+
# watch window is clean.
505+
# @section -- Arm64 Pilot Worker
506+
replicaCount: 1
507+
# -- Pin to the arm64 Karpenter nodepool's label.
508+
# @section -- Arm64 Pilot Worker
509+
nodeSelector:
510+
arch: arm64
511+
# -- Match the arm64 nodepool's taint so only this deployment schedules there.
512+
# @section -- Arm64 Pilot Worker
513+
tolerations:
514+
- key: arch
515+
operator: Equal
516+
value: arm64
517+
effect: NoSchedule
518+
480519
# -- Clock scheduler subchart overrides (lago-rails)
481520
# @default -- See child values
482521
# @section -- Clock

0 commit comments

Comments
 (0)