Reputation: 1
In order to differentiate between environments within my codebase across AWS App Runner instances corresponding to each environment (dev/stage/prod), I was planning to use a reference to the branch name that a given App Runner instance is deployed from. This is because there will be a separate branch (with a relevant name) in the source code repo that corresponds to each environment.
How can I obtain this? When running printenv
in both the build and run stages of the app, I did not see any environment variables that were set natively that corresponded to branch name, so am wondering if there is another option here. If there is no native option to do so, is my best bet to set up a custom CI/CD pipeline in Github that passes this into the App Runner instance?
Upvotes: 0
Views: 101