Each environment has its own set of environment variables set in the CI, so when I trigger build for a specified environment it picks up relevant environment variables and builds code for them.
The thing is though, in an ideal world you shouldn't be building for each environment, which is what I was driving at - build once and move that same build through environments. I've done this on CircleCI, but I'm far from a devops expert and how to move the same build through environments using triggers escapes me. If anybody can provide any insight, that'd be super!
It is generally a good idea to build artifact once and then move it across environments (e.g. Docker image).
However, it is not always possible to do so, e.g. if you use Create React App Environment Variables to point to correct API endpoint etc.
In the case of this article, we are also limited to what App Engine Standard Environment provides us with.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi Adam,
Each environment has its own set of environment variables set in the CI, so when I trigger build for a specified environment it picks up relevant environment variables and builds code for them.
Let me know if it makes sense
The thing is though, in an ideal world you shouldn't be building for each environment, which is what I was driving at - build once and move that same build through environments. I've done this on CircleCI, but I'm far from a devops expert and how to move the same build through environments using triggers escapes me. If anybody can provide any insight, that'd be super!
It is generally a good idea to build artifact once and then move it across environments (e.g. Docker image).
However, it is not always possible to do so, e.g. if you use Create React App Environment Variables to point to correct API endpoint etc.
In the case of this article, we are also limited to what App Engine Standard Environment provides us with.