diff --git a/build.sh b/build.sh index 3318b37..3fca883 100644 --- a/build.sh +++ b/build.sh @@ -2,15 +2,19 @@ export DATE=$(date '+%Y-%m-%d') export IMAGENAME=plextraktsync export OLDDATE=$(cat .build) +export ENDPOINT=ghostklart #docker stop officeproxy #docker rm officeproxy -docker rmi registry.ghostklart.com/dtibragimov/$IMAGENAME:$OLDDATE -f +docker rmi $ENDPOINT/$IMAGENAME:$OLDDATE -f + +git commit -am "$DATE" +git push touch .build echo $DATE > .build -docker build -t registry.ghostklart.com/dtibragimov/$IMAGENAME:$DATE . -docker tag registry.ghostklart.com/dtibragimov/$IMAGENAME:$DATE registry.ghostklart.com/dtibragimov/$IMAGENAME:latest +docker build -t $ENDPOINT/$IMAGENAME:$DATE . +docker tag $ENDPOINT/$IMAGENAME:$DATE $ENDPOINT/$IMAGENAME:latest echo "y" | docker system prune -docker push registry.ghostklart.com/dtibragimov/$IMAGENAME -a +docker push $ENDPOINT/$IMAGENAME -a