-
Notifications
You must be signed in to change notification settings - Fork 3
Environment variables
At times it will be necessary to deploy a change to environment variables outside of the normally scheduled sprint deploys. Depending on whether the variables are sensitive or not, we will need to approach the problem two different ways:
Non-sensitive variables are handled with the manifest files which are in the code base. When we want to change them, we need deploy those changes to the codebase. An example is updating the FECFormat version when EFO releases a new version.
- Create a branch off of the one responsible for deploying the environment you intend to update:
develop -> dev
release/sprint-x -> stage
release/test -> test
main -> prod
- Update the environment variables in the manifest files.
- Create a PR for that branch into the target branch. If the deploy needs to happen on a certain date, specify that in the PR title. example:
[MERGE on 05/27]... - If the change is for Production, before merging, re-deploy production in Circle from the last deploy to identify potential platform/dependency issues.
- After approval, the creator of the branch can merge the PR, initiating the deploy.
- Create a backfill PR to develop and merge after approval.
We do not handle sensitive variables with the manifest files. They are instead changed directly on the creds service. Instructions for updating the creds service can be found in the team Cloud Foundry docs. 🔒
fec.gov has a good wiki: https://github.com/fecgov/openFEC/wiki/Switch-out-cf-environment-variables
- Switch out env vars with
cf env [appname]andcf uups, not cloud.gov dashboard - Rebuild in Circle, never restage apps in Cloud.gov (causes downtime)