Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for tagging Docker image with latest Git commit hash #22

Open
mwvaughn opened this issue Aug 7, 2019 · 2 comments
Open

Support for tagging Docker image with latest Git commit hash #22

mwvaughn opened this issue Aug 7, 2019 · 2 comments
Assignees
Labels
enhancement New feature or request test please Need help validating a feature or fix
Milestone

Comments

@mwvaughn
Copy link

mwvaughn commented Aug 7, 2019

A workflow that grew out of some user's CICD workflows is to tell abaco deploy to override the value specified by DOCKER_IMAGE_VERSION in the reactor.rc file with the current Git repo short hash.

This is achieved by detecting the hash and passing it to the -t option, but this requires a separate, out-of-band step to detect the hash.

Extend the abaco deploy workflow to support this automatically:

  1. Add DOCKER_USE_COMMIT_HASH as a reactor.rc variable
  2. Add detection of current git commit hash to abaco deploy
  3. Update behavior of -t so the image tag is set in the following order when DOCKER_USE_COMMIT_HASH=1

Argument -t [value] > [git commit hash] > latest if git | DOCKER_IMAGE_VERSION if ! git

@mwvaughn mwvaughn added the enhancement New feature or request label Aug 7, 2019
@mwvaughn mwvaughn added this to the v1.3.0 milestone Aug 7, 2019
@mwvaughn mwvaughn self-assigned this Aug 7, 2019
@mwvaughn
Copy link
Author

mwvaughn commented Aug 7, 2019

Implemented in e1b4cd0

@mwvaughn mwvaughn closed this as completed Aug 7, 2019
@mwvaughn
Copy link
Author

Reopening to test

@mwvaughn mwvaughn reopened this Aug 13, 2019
@mwvaughn mwvaughn added the test please Need help validating a feature or fix label Aug 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request test please Need help validating a feature or fix
Projects
None yet
Development

No branches or pull requests

1 participant