Correct the build scripts.
This commit is contained in:
@@ -3,8 +3,8 @@
|
|||||||
# this file is intended to build the docker image and push to the correct repository. Intended to be run by my buildbot instance.
|
# this file is intended to build the docker image and push to the correct repository. Intended to be run by my buildbot instance.
|
||||||
|
|
||||||
# first just build, tag, and push
|
# first just build, tag, and push
|
||||||
docker build -t viker.cheezers.net:5000/agon:latest .
|
docker build -t viker.cheezers.net:5000/agon:develop .
|
||||||
docker push viker.cheezers.net:5000/agon:latest
|
docker push viker.cheezers.net:5000/agon:develop
|
||||||
|
|
||||||
# check if there is a git tag. if so, tag with that tag and push again
|
# check if there is a git tag. if so, tag with that tag and push again
|
||||||
# expecting tag to be 6 characters long. otherwise isn't not the right tag
|
# expecting tag to be 6 characters long. otherwise isn't not the right tag
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/bash -x
|
||||||
|
|
||||||
|
# this file is intended to build the docker image and push to the correct repository. Intended to be run by my buildbot instance.
|
||||||
|
|
||||||
|
# check if there is a git tag. if so, tag with that tag and release
|
||||||
|
# expecting tag to be 6 characters long. otherwise isn't not the right tag
|
||||||
|
GITTAG=$(git describe --tags)
|
||||||
|
length=${#GITTAG}
|
||||||
|
|
||||||
|
if [ $length -eq 6 ]; then
|
||||||
|
docker build -t viker.cheezers.net:5000/agon:release -t viker.cheezers.net:5000/agon:$GITTAG .
|
||||||
|
docker push viker.cheezers.net:5000/agon:release iker.cheezers.net:5000/agon:$GITTAG
|
||||||
|
else
|
||||||
|
docker build -t viker.cheezers.net:5000/agon:release .
|
||||||
|
docker push viker.cheezers.net:5000/agon:release
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user