-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcloudbuild.yaml
More file actions
56 lines (50 loc) · 1.49 KB
/
cloudbuild.yaml
File metadata and controls
56 lines (50 loc) · 1.49 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
steps:
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: 'bash'
args:
- '-c'
- |
gsutil cp gs://findup/$_ENV_PATH ./ExpressProject/.env
- name: 'gcr.io/cloud-builders/docker'
args:
- 'build'
- '-t'
- 'asia-southeast2-docker.pkg.dev/$PROJECT_ID/$_REPO_NAME/findup-api-$_CONTEXT:$COMMIT_SHA'
- '-f'
- 'ExpressProject/Dockerfile'
- 'ExpressProject'
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'asia-southeast2-docker.pkg.dev/$PROJECT_ID/$_REPO_NAME/findup-api-$_CONTEXT:$COMMIT_SHA']
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: 'gcloud'
args:
- 'run'
- 'deploy'
- 'run-findup-$_CONTEXT'
- '--image'
- 'asia-southeast2-docker.pkg.dev/$PROJECT_ID/$_REPO_NAME/findup-api-$_CONTEXT:$COMMIT_SHA'
- '--region'
- 'asia-southeast2'
- '--add-cloudsql-instances'
- '$PROJECT_ID:$_SQL_INSTANCE'
- '--allow-unauthenticated'
- '--memory'
- '4Gi'
- '--cpu'
- '4'
- '--cpu-boost'
- name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
entrypoint: 'gcloud'
args:
- 'run'
- 'services'
- 'update-traffic'
- 'run-findup-$_CONTEXT'
- '--to-latest'
- '--region'
- 'asia-southeast2'
images:
- 'asia-southeast2-docker.pkg.dev/$PROJECT_ID/$_REPO_NAME/findup-api-$_CONTEXT:$COMMIT_SHA'
logsBucket: 'gs://findup-logs/cloud-build/$_CONTEXT/logs'
options:
logging: GCS_ONLY