I want to add an environment-specific variable to the service image tag.
For example
image: some-image:{$env_var}
I have tried:
- some-image:$env_var
- "some-image:${env_var}"
- "some-image:{{$env_var}}"
Hello,
I've just published an article and a video showing how you can use a variable as the image name.
This solution is based on Dynamic Pipelines and requires a Forge app.
Hope this helps,
Caterina
Hi @jj471 and welcome to the community.
I'm afraid that it is not possible to use an environment variable in the Docker image name at the moment. The image name and version need to be specified in the yaml file without the use of variables.
We have a feature request for what you are asking in our issue tracker:
If you'd be interested in this, I would suggest that you add your vote in the feature request (by selecting the Vote for this issue link) as the number of votes helps the development team and product managers better understand the demand for new features. You are more than welcome to leave any feedback, and you can also add yourself as a watcher (by selecting the Start watching this issue link) if you'd like to get notified via email on updates.
Implementation of new features is done as per our policy here and any updates will be posted in the feature request.
Please feel free to let me know if you have any questions.
Kind regards,
Theodora
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.