From 9140f2a52b617e8e333101cc548a8e75f026e82d Mon Sep 17 00:00:00 2001 From: Tom Gallacher Date: Thu, 20 Oct 2016 14:55:05 +0100 Subject: [PATCH] ci: add a deployment script --- Makefile | 2 +- bin/deploy | 12 ++++++++++++ bin/{setup.sh => setup} | 0 circle.yml | 6 ++---- 4 files changed, 15 insertions(+), 5 deletions(-) create mode 100755 bin/deploy rename bin/{setup.sh => setup} (100%) diff --git a/Makefile b/Makefile index ecb32ac1..6038a5c8 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ .PHONY: check check: - @./bin/setup.sh + @./bin/setup .PHONY: test-cloudapi-graphql test-cloudapi-graphql: diff --git a/bin/deploy b/bin/deploy new file mode 100755 index 00000000..bfc47d50 --- /dev/null +++ b/bin/deploy @@ -0,0 +1,12 @@ +#! /usr/bin/env bash +triton env + +docker-compose build +#docker-compose push + +export DOCKER_HOST=$_DOCKER_HOST +export DOCKER_CERT_PATH=$_DOCKER_CERT_PATH +export DOCKER_TLS_VERIFY=$_DOCKER_TLS_VERIFY + +docker-compose pull +docker-compose up -d diff --git a/bin/setup.sh b/bin/setup similarity index 100% rename from bin/setup.sh rename to bin/setup diff --git a/circle.yml b/circle.yml index be763917..0f694ae0 100644 --- a/circle.yml +++ b/circle.yml @@ -25,10 +25,8 @@ deployment: production: # just a label; label names are completely up to you branch: master commands: - - ./bin/setup.sh - - docker-compose pull - - docker-compose build - - docker-compose up -d + - ./bin/setup + - ./bin/deploy ## Custom notifications # notify: