forked from miraisolutions/SmaRP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
cloudbuild.yaml
40 lines (40 loc) · 1.1 KB
/
cloudbuild.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
steps:
- name: 'gcr.io/cloud-builders/docker'
args: ['pull', 'eu.gcr.io/mirai-sbb/smarp:latest']
- name: 'gcr.io/cloud-builders/docker'
args: [
'build',
'--cache-from',
'eu.gcr.io/mirai-sbb/smarp:latest',
'-t', 'eu.gcr.io/mirai-sbb/smarp:latest',
'-t', 'eu.gcr.io/mirai-sbb/smarp:$COMMIT_SHA',
'.'
]
- name: 'gcr.io/cloud-builders/docker'
args: ["push", "eu.gcr.io/mirai-sbb/smarp:$COMMIT_SHA"]
- name: 'gcr.io/cloud-builders/docker'
args: ["push", "eu.gcr.io/mirai-sbb/smarp:latest"]
- name: 'gcr.io/cloud-builders/kubectl'
args:
- set
- image
- deployment
- smarp
- smarp=eu.gcr.io/mirai-sbb/smarp:$COMMIT_SHA
env:
- 'CLOUDSDK_COMPUTE_ZONE=europe-west1-b'
- 'CLOUDSDK_CONTAINER_CLUSTER=smarp'
- name: 'gcr.io/cloud-builders/kubectl'
args:
- annotate
- --overwrite
- deployment
- smarp
- DEPLOY_SHA=$COMMIT_SHA
env:
- 'CLOUDSDK_COMPUTE_ZONE=europe-west1-b'
- 'CLOUDSDK_CONTAINER_CLUSTER=smarp'
images:
- 'eu.gcr.io/mirai-sbb/smarp:$COMMIT_SHA'
- 'eu.gcr.io/mirai-sbb/smarp:latest'
timeout: 3600s