Merge pull request #126 from Zoey2936/patch-1

Add stable tag on push
This commit is contained in:
El RIDO 2022-12-22 17:53:57 +01:00 committed by GitHub
commit 0ddd1dd1c8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View file

@ -18,6 +18,7 @@ All images contain a release version of PrivateBin and are offered with the foll
- `latest` is an alias of the latest pushed image, usually the same as `nightly`, but excluding `edge`
- `nightly` is the latest released PrivateBin version on an upgraded Alpine release image, including the latest changes from the docker image repository
- `edge` is the latest released PrivateBin version on an upgraded Alpine edge image
- `stable` contains the latest commit of the master branch of the [PrivateBin/docker-nginx-fpm-alpine repo](https;//github.com/docker-nginx-fpm-alpine), gets pushed on new commmits
- `1.5.0` contains PrivateBin version 1.5.0 on the latest tagged release of the docker image repository - gets updated when important security fixes are released for Alpine or upon new Alpine releases
- `1.5.0-...` are provided for selecting specific, immutable images

View file

@ -75,6 +75,9 @@ main() {
sed -e 's/^FROM alpine:.*$/FROM alpine:edge/' Dockerfile > Dockerfile.edge
BUILD_ARGS="-f Dockerfile.edge --tag $IMAGE:edge $BUILD_ARGS"
IMAGE="$IMAGE:edge"
elif [ "$EVENT" = push ] ; then
BUILD_ARGS="--tag $IMAGE:latest --tag $IMAGE:$TAG --tag ${IMAGE}:${TAG%%-*} --tag ${IMAGE}:stable $BUILD_ARGS"
IMAGE="$IMAGE:latest"
else
BUILD_ARGS="--tag $IMAGE:latest --tag $IMAGE:$TAG --tag ${IMAGE}:${TAG%%-*} $BUILD_ARGS"
IMAGE="$IMAGE:latest"