jenkinsci / jenkinsci/docker-plugin
[JENKINS-39104] Add new template build step should do variable substitution
- Dominant language
- Java
- Stars
- 498
- Forks
- 324
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 2
Description
The "Add a new template to all docker clouds" build step makes an excellent follow-on build step to the "Build / Publish Docker Containers" build step.
e.g. you can create an image tagged as myregistry:1234/myimage:version-${BUILD_NUMBER} and you'll get myimage:version-1, myimage:version-2 etc pushed to your registry in subsequent builds.
However, if you use the "Add a new template to all docker clouds" build step and specify a "Docker Image" field of "myregistry:1234/myimage:version-${BUILD_NUMBER}" then that's exactly what you'll get - it won't replace ${BUILD_NUMBER} with the build number.
What should happen is that all of the plain-text fields should be subjected to Jenkins' variable substitution so that all text fields can be parameterised.
---
Originally reported by pjdarton, imported from: Add new template build step should do variable substitution
Raw content of original issue
The "Add a new template to all docker clouds" build step makes an excellent follow-on build step to the "Build / Publish Docker Containers" build step.
e.g. you can create an image tagged as myregistry:1234/myimage:version-${BUILD_NUMBER} and you'll get myimage:version-1, myimage:version-2 etc pushed to your registry in subsequent builds.
However, if you use the "Add a new template to all docker clouds" build step and specify a "Docker Image" field of "myregistry:1234/myimage:version-${BUILD_NUMBER}" then that's exactly what you'll get - it won't replace ${BUILD_NUMBER} with the build number.What should happen is that all of the plain-text fields should be subjected to Jenkins' variable substitution so that all text fields can be parameterised.
Contributor guide
Assessment
This issue has not been assessed yet.