Docker Community Forums

Share and learn in the Docker community.

Docker Hub Build Parameters

dockerhub
build

(Jenkink) #1

hi all relatively new to dockerhub i had a quick question, is it possible to get build parameters in an automated dockerhub built ie --build-arg GIT_SHA1=$(git rev-parse --short HEAD) . as im trying to attach a git hash to my docker environment, any help is appreciated!


(Lizter) #2

Are you whitelisting GIT_SHA1 in your Dockerfile? E.g. ARG GIT_SHA1
All build args that are not part of the predefined ones needs to be whitelisted.
Have you verified that the substitution works?