aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/docker_deploy.sh
diff options
context:
space:
mode:
authorRJ Catalano <rj@monax.io>2017-02-03 08:53:30 +0800
committerRJ Catalano <rj@monax.io>2017-02-10 01:30:59 +0800
commitd76d9d41690b69622b703b7a3f567e830d095f9e (patch)
tree7f3ad0f1070355e2ed98da4d4a98fd3d97a7c997 /scripts/docker_deploy.sh
parent00feec567afbedc0b09805d7226c94c1d96c0c2a (diff)
downloaddexon-solidity-d76d9d41690b69622b703b7a3f567e830d095f9e.tar.gz
dexon-solidity-d76d9d41690b69622b703b7a3f567e830d095f9e.tar.zst
dexon-solidity-d76d9d41690b69622b703b7a3f567e830d095f9e.zip
create automated docker deployment
Signed-off-by: RJ Catalano <rj@monax.io>
Diffstat (limited to 'scripts/docker_deploy.sh')
-rwxr-xr-xscripts/docker_deploy.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/docker_deploy.sh b/scripts/docker_deploy.sh
new file mode 100755
index 00000000..f4c61601
--- /dev/null
+++ b/scripts/docker_deploy.sh
@@ -0,0 +1,17 @@
+#!/usr/bin/env sh
+
+docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD";
+version=version=$(grep -oP "PROJECT_VERSION \"?\K[0-9.]+(?=\")"? $(dirname "$0")/CMakeLists.txt)
+if [ "$TRAVIS_BRANCH" == "develop" ]; then
+ docker tag ethereum/solc:build ethereum/solc:nightly;
+ docker tag ethereum/solc:build ethereum/solc:nightly-"$version"-"$TRAVIS_COMMIT"
+ docker push ethereum/solc:nightly-"$version"-"$TRAVIS_COMMIT";
+ docker push ethereum/solc:nightly;
+elif [ "$TRAVIS_BRANCH" == "release"]; then
+ docker tag ethereum/solc:build ethereum/solc:stable;
+ docker tag ethereum/solc:build ethereum/solc:"$version";
+ docker tag ethereum/solc:build ethereum/solc:
+ docker push ethereum/solc;
+ docker push ethereum/solc:"$version";
+ docker push ethereum/solc:stable;
+fi \ No newline at end of file