Add configurable config profile override for staging and shared master#435
Conversation
- Introduced `config_profile` input in `deploy-graph-ladybug.yml` and `lbug_shared_config_profile` in `deploy-graph.yml` to allow for configuration profile overrides. - Updated `staging.yml` to include the new shared config profile variable. - Enhanced `graph-ladybug.yaml` to accept a `ConfigProfile` parameter for staging deployments. - Modified `graph_tier.py` to utilize the config profile for shared master deployments, enabling staging to use production configurations.
…staging-configurable-profile
|
@claude please review this PR |
|
Claude finished @jfrench9's task in 1m 25s —— View job PR Review: Add configurable config profile override for staging and shared master
Overall the PR is clean and the approach is well-designed — additive, backward-compatible, and logically consistent. A few issues worth addressing before merge. Issues1.
|
| # | Severity | File | Issue |
|---|---|---|---|
| 1 | Medium | graph_tier.py:103 |
os.getenv() violates centralized config rule |
| 2 | Low-Medium | deploy-graph.yml:404 |
Unsanitized input in yq shell command |
| 3 | Low | graph-ladybug.yaml:448 / graph_tier.py:104 |
Inconsistency between where env var is set vs applied |
| 4 | Nit | staging.yml:457 |
Redundant ` |
The architecture and overall approach are solid. Issue #1 is the main one to fix before merge given the explicit repo convention.
|
- Added validation for the config profile in the deploy-graph workflow to ensure it matches known environments (production, staging, development). - Updated the setup script to set the default config profile for staging to "staging". - Adjusted the CloudFormation template to conditionally set the config profile based on the writer tier. - Introduced a new environment variable for the config profile in the EnvConfig class to support dynamic configuration.
Summary
Introduces support for overriding the configuration profile used in staging and shared master deployments. This allows deployments to target different configuration profiles without requiring code changes, enabling more flexible environment management.
Key Accomplishments
config_profileinput/parameter to thedeploy-graph.ymlanddeploy-graph-ladybug.ymlGitHub Actions workflows, allowing the configuration profile to be specified at deploy time.staging.ymlworkflow so it propagates correctly during staging deployments.graph-ladybug.yamlCloudFormation template to accept and pass through the config profile override as a parameter.graph_tier.pyto read and apply the config profile override, enabling the application to resolve the correct configuration at runtime based on the provided profile.Breaking Changes
None. The config profile override is additive — existing deployments that do not specify a profile will continue to use the default behavior.
Testing Notes
Infrastructure Considerations
🤖 Generated with Claude Code
Branch Info:
feature/staging-configurable-profilemainCo-Authored-By: Claude noreply@anthropic.com