-
Notifications
You must be signed in to change notification settings - Fork 0
/
cloudbuild.yaml
30 lines (25 loc) · 1.16 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
steps:
- name: 'gcr.io/cloud-builders/docker'
args: [ 'pull', 'gcr.io/$PROJECT_ID/builder-api.dungeon.studio' ]
- name: 'gcr.io/cloud-builders/docker'
args: [ 'pull', 'gcr.io/$PROJECT_ID/api.dungeon.studio' ]
- name: 'gcr.io/cloud-builders/docker'
args: [ 'build',
'--cache-from', 'gcr.io/$PROJECT_ID/builder-api.dungeon.studio',
'-t', 'gcr.io/$PROJECT_ID/builder-api.dungeon.studio',
'--target', 'builder',
'-f', 'Dockerfile', '.' ]
- name: 'gcr.io/cloud-builders/docker'
args: [ 'build',
'--cache-from', 'gcr.io/$PROJECT_ID/builder-api.dungeon.studio',
'--cache-from', 'gcr.io/$PROJECT_ID/api.dungeon.studio',
'-t', 'gcr.io/$PROJECT_ID/api.dungeon.studio',
'-t', 'gcr.io/$PROJECT_ID/api.dungeon.studio:$BRANCH_NAME',
'-t', 'gcr.io/$PROJECT_ID/api.dungeon.studio:$COMMIT_SHA',
'-f', 'Dockerfile', '.' ]
images:
- 'gcr.io/$PROJECT_ID/builder-api.dungeon.studio'
- 'gcr.io/$PROJECT_ID/api.dungeon.studio'
- 'gcr.io/$PROJECT_ID/api.dungeon.studio:$BRANCH_NAME'
- 'gcr.io/$PROJECT_ID/api.dungeon.studio:$COMMIT_SHA'
timeout: 60m