NGenetzky / docker-yocto

0 stars 0 forks source link

Attach metadata to image #4

Open NGenetzky opened 4 years ago

NGenetzky commented 4 years ago

The simple stuff would be utilizing the following variables.

    SOURCE_BRANCH: the name of the branch or the tag that is currently being tested.
    SOURCE_COMMIT: the SHA1 hash of the commit being tested.
    COMMIT_MSG: the message from the commit being tested and built.
    DOCKER_REPO: the name of the Docker repository being built.
    DOCKERFILE_PATH: the dockerfile currently being built.
    DOCKER_TAG: the Docker repository tag being built.
    IMAGE_NAME: the name and tag of the Docker repository being built. (This variable is a combination of DOCKER_REPO:DOCKER_TAG.)

If you wanted to take it up a notch, then Custom build phase hooks could provide arbitrary ARGS/--build-args

NGenetzky commented 4 years ago

dockcross is an excellent example for this.