Add staging environment and deploy job

This commit is contained in:
James Polley 2018-06-10 19:12:14 +10:00
parent f14fdd6f93
commit 6d50900433

View file

@ -59,11 +59,27 @@ k8s-2019_dev-deploy:
- kubectl --token "${GL_KUBE_TOKEN}" set image deployment/symposion-app symposion-app=asia.gcr.io/linuxconfsydney/symposion_app_2019_dev:$CI_COMMIT_SHA
when: manual
only:
- dev/2019
- dev/*
environment:
name: dev_2019
url: https://dev.lca2019.org
k8s-2019_staging-deploy:
image: google/cloud-sdk
stage: deploy
script:
- echo "${CA_CERT}" > cert.crt
- kubectl config set-cluster cluster --server="${KUBE_SERVER}" --embed-certs=true --certificate-authority=cert.crt
- kubectl config set-context cluster --cluster=cluster --namespace=lca2019-staging --user=gitlab-ci
- kubectl config use-context cluster
- kubectl --token "${GL_KUBE_TOKEN}" set image deployment/symposion-app symposion-app=asia.gcr.io/linuxconfsydney/symposion_app_2019_dev:$CI_COMMIT_SHA
when: manual
only:
- dev/2019
environment:
name: staging
url: https://staging.lca2019.org
.docs_template: &sphinx
image: alpine
script: