Skip to content

Commit 6374cf6

Browse files
authored
Adds back the build environment image to the precloudbuild pipeline (#4372)
1 parent 205ffbd commit 6374cf6

File tree

1 file changed

+30
-3
lines changed

1 file changed

+30
-3
lines changed

build/release/pre_cloudbuild.yaml

Lines changed: 30 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ steps:
3333
- .
3434

3535
#
36-
# Creates the initial make + docker build platform
36+
# Creates the initial make + docker build platform.
37+
# This image is used to run subsequent 'make' commands.
3738
#
3839
- name: ubuntu
3940
args:
@@ -46,7 +47,29 @@ steps:
4647
args: [build, -f, Dockerfile.build, -t, make-docker, .]
4748

4849
#
49-
# Ensure example images exists
50+
# Pull the build environment image if it exists.
51+
# This image contains all the tools needed to run the build and test commands.
52+
#
53+
- name: make-docker
54+
id: pull-build-image
55+
dir: build
56+
env: ['REGISTRY=us-docker.pkg.dev/${PROJECT_ID}/ci']
57+
args: [pull-build-image]
58+
waitFor:
59+
- build-make-docker
60+
61+
#
62+
# Build the build environment image if we were unable to pull it.
63+
#
64+
- name: "make-docker"
65+
id: "ensure-build-image"
66+
dir: "build"
67+
args: ["ensure-build-image"]
68+
waitFor:
69+
- pull-build-image
70+
71+
#
72+
# Ensure example images exists. Requires build image to exist in Cloudbuild environment.
5073
#
5174
- name: make-docker
5275
id: test-examples-on-gar
@@ -55,14 +78,18 @@ steps:
5578
- REGISTRY=us-docker.pkg.dev/${PROJECT_ID}
5679
- DOCKER_RUN_ARGS=--network=cloudbuild
5780
args: [test-examples-on-gar]
81+
waitFor:
82+
- ensure-build-image
5883

5984
#
60-
# Deploys the site by taking in the base version and deploying the previous version
85+
# Deploys the site by taking in the base version and deploying the previous version.
6186
#
6287
- name: make-docker
6388
id: release-deploy-site
6489
dir: build
6590
env:
6691
- VERSION=${_VERSION}
6792
args: [release-deploy-site]
93+
waitFor:
94+
- test-examples-on-gar
6895
timeout: 5400s

0 commit comments

Comments
 (0)