-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathcloudbuild.yaml
46 lines (42 loc) · 988 Bytes
/
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
41
42
43
44
45
46
steps:
# slack deployment status
- name: "gcr.io/cloud-builders/curl"
args:
[
"-X",
"POST",
"-H",
"Content-type: application/json",
"--data",
'{"text":"`$REPO_NAME:$BRANCH_NAME$TAG_NAME` build started!"}',
"${_WEBHOOK_URL}",
]
# build docker image
- name: "gcr.io/cloud-builders/docker"
args:
[
"build",
"--build-arg",
"TAG_NAME=$TAG_NAME",
"--build-arg",
"NPM_TOKEN=$_NPM_TOKEN",
".",
]
timeout: 1500s
# slack deployment status
- name: "gcr.io/cloud-builders/curl"
args:
[
"-X",
"POST",
"-H",
"Content-type: application/json",
"--data",
'{"text":"`$REPO_NAME:$BRANCH_NAME$TAG_NAME` build completed!"}',
"${_WEBHOOK_URL}",
]
timeout: 1500s
# env defaults
substitutions:
_NPM_TOKEN: NPM registry private package
_WEBHOOK_URL: slack_notification_webhook_url