Looking to deploy with actions to multiple environments. Environments are our logical environments, like Dev, Uat, Pro, etc. Deploy mechanic is same for all environments.
Given that the deploy is deploy x, y, z, and x, y, z are variables with differing values for each environment, what is the best practice for handling this in actions?
Octopus has scoped variables. Defined once, and per-environment values.
Here are some options I considered:
Define Actions Environments and:
- Use Environment Secrets - con is maintainability for non-secrets (can't just see plain-text things)
- SWITCH-type statement on Actions Environment to set env vars (seems best so far)
The Actions Environments seems to be the way to go for per-environment differentiation, but it's smelling to keep the var values in GitHub and feeling like should be externalized completely as there's no mechanism for "config".
Please let me know if you have approached such case. Thanks!
Edit: 12-factor app says "store config in the environment" and I think that means in AWS, that I have per-env SSM params and use the GH Actions Environments to pull the respective params' values into env vars. This feels most correct.