Skip to content

fix(ci): forward CDK_PLATFORM_COSTS_ENABLED to the platform deploy - #1245

Merged
philmerrell merged 1 commit into
developfrom
feature/forward-platform-costs-flag
Sep 23, 2026
Merged

philmerrell merged 1 commit into
developfrom
feature/forward-platform-costs-flag

Conversation

@philmerrell

Copy link
Copy Markdown
Contributor

infrastructure/lib/config.ts reads CDK_PLATFORM_COSTS_ENABLED (#1235) and docs/specs/platform-cost-visibility.md tells operators to set it for the platform.yml deploy, but the workflow never forwarded it. Setting the GitHub variable did nothing; only platformCosts.enabled in cdk.json context could turn the sync on.

This adds it to the deploy job env, which is the only job in platform.yml that runs synth/deploy and where every other CDK_* var is forwarded.

Safe when unset: an unset var arrives as "", which is falsy in config.ts, so it falls back to the platformCosts.enabled context (default off). Only the literal "true" enables the feature. Nothing changes for environments that set neither.

Note for 1.24.0: the release notes on release/1.24.0 (#1244) say the variable isn't forwarded yet. That stays true unless this fix also lands on the release branch.

No test asserts workflow env forwarding for other CDK_* vars, so there was no existing test to extend. repo-shape.test.ts still passes.

🤖 Generated with Claude Code

config.ts reads it and the platform-cost-visibility spec tells operators to
set it, but platform.yml never passed it through, so the GitHub variable had
no effect and only cdk.json context could enable the sync.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@philmerrell

Copy link
Copy Markdown
Contributor Author

Cherry-picked onto release/1.24.0 (#1244) with the matching release notes/changelog update, so this ships in 1.24.0. This PR still lands it on develop.

@philmerrell
philmerrell merged commit aca82b9 into develop Sep 23, 2026
6 checks passed
@philmerrell
philmerrell deleted the feature/forward-platform-costs-flag branch September 23, 2026 01:50
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.

1 participant