feat(supervisor): per-org placement overrides for run pods - #4655
Conversation
KUBERNETES_ORG_PLACEMENT_OVERRIDES takes JSON keyed by org id, adding node selector entries and tolerations to that org's run pods so an operator can pin an org onto a dedicated node pool. Validated at startup so a typo fails fast instead of rejecting every pod create.
Blank env value now means no overrides instead of failing startup. Tolerations also accept an array of entries to match the Helm list shape, scalar node selector values are coerced to strings, keys and values are trimmed, and empty selector values are rejected since they would pin the org to nothing. Startup fails when an override pins the large-machine pool while non-large presets are required to stay off it. The supervisor logs configured override orgs at startup and warns when an override replaces a default node selector key.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
Included review availability: Your plan includes up to 10 reviews per rolling hour; 9 remain after this review. 📜 Recent review details⏰ Context from checks skipped due to timeout. (8)
WalkthroughThe supervisor now accepts Merge Risk: ⚪ Minimal · up to The supervisor adds per-organization pod placement overrides with startup validation and Helm configuration support; no actionable merge-blocking risk remains beyond normal checks and review. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🧭 Helm Chart Prerelease PublishedVersion: Install: helm upgrade --install trigger \
oci://ghcr.io/triggerdotdev/charts/trigger \
--version "4.5.11-pr4655.2866fc9"
|
…t wording The override lookup is exact, so a padded or blank org key would parse at startup and then never match a run. The release note now describes the user-visible result and the docs row states the selector-override vs toleration-append semantics separately.
The supervisor now supports routing an organization's runs to specific nodes.
KUBERNETES_ORG_PLACEMENT_OVERRIDEStakes JSON keyed by the internal org ID, adding node selector entries and tolerations to that org's run pods, e.g. to route an org onto a dedicated, tainted node pool:{"<orgId>": {"nodeSelector": {"pool": "dedicated"}, "tolerations": "dedicated=runs:NoSchedule"}}The node selector merges over the defaults (the override wins on key collision, with a warning logged). Tolerations append to the existing runner and scheduled-run sets. Overrides are validated at startup similar to
KUBERNETES_RUNNER_TOLERATIONS.Exposed in the Helm chart as
supervisor.config.kubernetes.orgPlacementOverrides, where tolerations can also be given as a list.