diff options
author | Mark Lechtermann <mark.lechtermann@gmail.com> | 2020-08-14 16:47:18 +0200 |
---|---|---|
committer | Mark Lechtermann <mark.lechtermann@gmail.com> | 2020-08-14 16:47:18 +0200 |
commit | b514609f4fa319491d1956205d98012b5fc59d9d (patch) | |
tree | 3dc68dc48dc467117c3129d26d6128a5528b63a6 /hooks | |
parent | 63aa250910f56c85a4481506fddd2930ed83665d (diff) |
Hash as Docker tag supported
Diffstat (limited to 'hooks')
-rwxr-xr-x | hooks/post_push | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/hooks/post_push b/hooks/post_push new file mode 100755 index 0000000..c3a2958 --- /dev/null +++ b/hooks/post_push @@ -0,0 +1,5 @@ +#!/bin/bash + +SHORTHASH="$(git rev-parse --short HEAD)" +docker tag $IMAGE_NAME $DOCKER_REPO:$SHORTHASH +docker push $DOCKER_REPO:$SHORTHASH
\ No newline at end of file |