File tree Expand file tree Collapse file tree 4 files changed +21
-11
lines changed Expand file tree Collapse file tree 4 files changed +21
-11
lines changed Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ echo $GCLOUD_KEY | base64 --decode > gcloud.p12
4+ gcloud auth activate-service-account 484500905059-bb55pm9ophqkbhkd1vrront20ati766f@developer.gserviceaccount.com --key-file gcloud.p12
5+ ssh-keygen -f ~ /.ssh/google_compute_engine -N " "
Original file line number Diff line number Diff line change 55 CLOUDSDK_COMPUTE_ZONE : us-central1-a
66 CLOUDSDK_CORE_PROJECT : circle-docker-hello
77 CLOUDSDK_CONTAINER_CLUSTER : cluster-1
8+ PATH : $PATH:/home/ubuntu/google-cloud-sdk/bin
89 python :
910 version : 2.7.3
1011
@@ -13,27 +14,21 @@ dependencies:
1314 - ~/kubernetes
1415 - ~/google-cloud-sdk
1516 pre :
16- - pip install pyopenssl
17- - ssh-keygen -f ~/.ssh/google_compute_engine -N ""
18- - if [ ! -d ~/google-cloud-sdk ]; then curl https://sdk.cloud.google.com | bash; fi
19- - ~/google-cloud-sdk/bin/gcloud components update preview
20- - echo $GCLOUD_KEY | base64 --decode > gcloud.p12
21- - ~/google-cloud-sdk/bin/gcloud auth activate-service-account 484500905059-bb55pm9ophqkbhkd1vrront20ati766f@developer.gserviceaccount.com --key-file gcloud.p12
22- - ~/google-cloud-sdk/bin/gcloud preview container pods list
23- - ./ensure-kubernetes-installed.sh
17+ - ./ensure-gcloud-installed.sh
2418 - sudo docker -d -D -e lxc -s btrfs --insecure-registry $EXTERNAL_REGISTRY_ENDPOINT :
2519 background : true
2620 - docker build -t $EXTERNAL_REGISTRY_ENDPOINT/hello:$CIRCLE_SHA1 .
2721
2822test :
2923 post :
30- - docker run -d -p 3000:3000 -e "SECRET_KEY_BASE=abcd1234" $EXTERNAL_REGISTRY_ENDPOINT/hello:$CIRCLE_SHA1; sleep 10
24+ - docker run -d -p 3000:3000 -e "SECRET_KEY_BASE=abcd1234" $EXTERNAL_REGISTRY_ENDPOINT/hello:$CIRCLE_SHA1
3125 - curl --retry 10 --retry-delay 5 -v http://localhost:3000
3226
3327deployment :
3428 prod :
3529 branch : master
3630 commands :
3731 # - docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS $EXTERNAL_REGISTRY_ENDPOINT
38- - envsubst < .kubernetes_auth.template > ~/.kubernetes_auth
39- - ./deploy.sh
32+ - docker push $EXTERNAL_REGISTRY_ENDPOINT/hello:$CIRCLE_SHA1
33+ - ./auth-gcloud.sh
34+ - ./rolling-update.sh
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ pip install pyopenssl
4+ if [ ! -d ~ /google-cloud-sdk ]; then
5+ curl https://sdk.cloud.google.com | bash;
6+ ~ /google-cloud-sdk/bin/gcloud components update preview
7+ fi
8+
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
13set -eu
24
35CTRL_BASENAME=railscontroller
You can’t perform that action at this time.
0 commit comments