Skip to content

fix(mailpit): independent replicaCount + nodeSelector/tolerations#33

Merged
kathrynalpert merged 1 commit into
mainfrom
feat/mailpit-scale-to-0
Jun 26, 2026
Merged

fix(mailpit): independent replicaCount + nodeSelector/tolerations#33
kathrynalpert merged 1 commit into
mainfrom
feat/mailpit-scale-to-0

Conversation

@kathrynalpert

Copy link
Copy Markdown
Contributor

What

Make the chart-native mailpit sink independently schedulable + scalable:

  • mailpit.replicaCount (default 1) — set 0 to scale the sink down when idle.
  • mailpit.nodeSelector / mailpit.tolerations (default empty) — place the sink on its own node pool instead of inheriting the xnat pod's.

Why

Adopting the native mailpit for test installs, we want the sink ephemeral (scaled to 0 between runs, scaled up by the test orchestrator) and on the general node pool — not occupying the xnat pod's tainted/sized nodes. Today replicas: 1 is hardcoded and nodeSelector/tolerations come from .Values.nodeSelector/.tolerations (the xnat pod's).

Behavior change

Existing mailpit.enabled users: the sink no longer inherits .Values.nodeSelector/.tolerations; defaults are empty (general pool). Set mailpit.nodeSelector/.tolerations to restore pinning.

Verified

helm template … --set mailpit.enabled=true --set mailpit.replicaCount=0 --set mailpit.nodeSelector.… renders replicas: 0 and the nodeSelector/tolerations correctly.

🤖 Generated with Claude Code

The chart-native mailpit sink hardcoded replicas: 1 and inherited the xnat
pod's nodeSelector/tolerations (.Values.nodeSelector), so it could not scale
to 0 when idle and was pinned to xnat's tainted/sized pool. Expose
mailpit.replicaCount (default 1) and mailpit.nodeSelector/.tolerations
(default empty) so an orchestrator can scale the sink 0<->1 per test run and
place it on the general node pool, independent of the xnat StatefulSet.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@spetrick spetrick left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@kathrynalpert kathrynalpert merged commit d1c6384 into main Jun 26, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants