diff --git a/.travis.yml b/.travis.yml index 3d217d5..180810e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,8 +15,4 @@ env: matrix: fast_finish: true -script: | - GO_VERSION=$(go version | awk 'print $3') - docker build -f Dockerfiles/Dockerfile."$GO_VERSION" -t canthefason/go-watcher:$WATCHER_VERSION-$GO_VERSION . - docker push canthefason/go-watcher:$WATCHER_VERSION-$GO_VERSION - +script: ./build.sh diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..1aa2ef6 --- /dev/null +++ b/build.sh @@ -0,0 +1,6 @@ +#!/bin/bash +GO_VERSION=$(go version | awk '{print $3}') + +/bin/bash -c "docker build -f Dockerfiles/Dockerfile.$GO_VERSION" -t "canthefason/go-watcher:$WATCHER_VERSION-$GO_VERSION" . + +docker push canthefason/go-watcher:$WATCHER_VERSION-$GO_VERSION