forked from GoogleCloudPlatform/cloud-sdk-docker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
cloudbuild.yaml
67 lines (61 loc) · 2.97 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
steps:
- name: 'gcr.io/cloud-builders/docker'
id: alpine
args: ['build', '-t', 'google/cloud-sdk:alpine', '-t', 'google/cloud-sdk:$TAG_NAME-alpine', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:alpine', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME-alpine', 'alpine/']
waitFor: ['-']
- name: 'gcr.io/cloud-builders/docker'
id: debian_slim
args: ['build', '-t', 'google/cloud-sdk:slim', '-t', 'google/cloud-sdk:$TAG_NAME-slim', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:slim', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME-slim', 'debian_slim/']
waitFor: ['-']
- name: 'gcr.io/cloud-builders/docker'
id: default
args: ['build', '-t', 'google/cloud-sdk:latest', '-t', 'google/cloud-sdk:$TAG_NAME', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:latest', '-t', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME', '.']
waitFor: ['-']
- name: 'gcr.io/cloud-builders/docker'
id: dockersecret
entrypoint: 'bash'
args: ['-c', 'docker login --username=$_USERNAME --password=$$PASSWORD']
secretEnv: ['PASSWORD']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:alpine']
waitFor: ['dockersecret', 'alpine']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:$TAG_NAME-alpine']
waitFor: ['dockersecret', 'alpine']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:alpine']
waitFor: ['dockersecret', 'alpine']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME-alpine']
waitFor: ['dockersecret', 'alpine']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:slim']
waitFor: ['dockersecret', 'debian_slim']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:$TAG_NAME-slim']
waitFor: ['dockersecret', 'debian_slim']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:slim']
waitFor: ['dockersecret', 'debian_slim']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME-slim']
waitFor: ['dockersecret', 'debian_slim']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:latest']
waitFor: ['dockersecret', 'default']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'google/cloud-sdk:$TAG_NAME']
waitFor: ['dockersecret', 'default']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:latest']
waitFor: ['dockersecret', 'debian_slim']
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/google.com/cloudsdktool/cloud-sdk:$TAG_NAME']
waitFor: ['dockersecret', 'debian_slim']
secrets:
- kmsKeyName: projects/google.com:cloudsdktool/locations/global/keyRings/docker/cryptoKeys/dockerhub-password
secretEnv:
PASSWORD: |
CiQA9btlfpg/kWmwXQvrNXtkVpu2tDdD2VOi1FYd3mmjCUGaK4YSNwC8sn1MepjracHAg8VAQEWm
s26BTGccqD1NTS83DGFdY9moRGhSPm4WJKCg2tTQKYeTfdqUjjM=
timeout: 1200s