This repository has been archived on 2021-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
Dockerfiles/shaarli/builder.sh

17 lines
449 B
Bash
Executable File

#!/bin/sh
#COMMIT_ID=$(git log -n 1 --pretty=format:%H -- shaarli/)
#LAST_COMMIT_ID=$(git log -n 1 --pretty=format:%H --)
COMMIT_ID=1
LAST_COMMIT_ID=1
if [ "$COMMIT_ID" == "$LAST_COMMIT_ID" ]; then
echo "build image"
docker build --no-cache -t registry.dryusdan.fr/dryusdan/shaarli shaarli/
docker push registry.dryusdan.fr/dryusdan/shaarli
docker rmi registry.dryusdan.fr/dryusdan/shaarli
else
echo "image is recent. No build"
fi