Skip to content

Commit 1c99d43

Browse files
craig[bot]rail
andcommitted
Merge #154142
154142: build: use docker image mirror r=ibreakthecloud a=rail Previously, some of our build steps pulled docker images from 3rd party repos (e.g. Docker Hub). These repos sometimes have reliability issues, which can cause our builds to fail. This commit updates our build steps to use a docker image mirror hosted in GCP Artifact Registry instead. Epic: none Release note: none Co-authored-by: Rail Aliiev <[email protected]>
2 parents bf7add6 + b226330 commit 1c99d43

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

build/teamcity-assert-clean.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,10 @@ if [[ "$(git status --porcelain 2>&1)" != "" ]]; then
3535
git status >&2 || true
3636
git diff -a >&2 || true
3737
echo "Nuking build cruft. Please teach this build to clean up after itself." >&2
38-
run docker run --volume="$root:/nuke" --workdir="/nuke" golang:stretch /bin/bash -c "git clean -ffdx ; git submodule foreach --recursive git clean -xffd" >&2
38+
# We use a docker image mirror to avoid pulling from 3rd party repos, which sometimes have reliability issues.
39+
# See https://cockroachlabs.atlassian.net/wiki/spaces/devinf/pages/3462594561/Docker+image+sync for the details.
40+
run docker run --volume="$root:/nuke" --workdir="/nuke" \
41+
us-east1-docker.pkg.dev/crl-docker-sync/docker-io/library/golang:stretch \
42+
/bin/bash -c "git clean -ffdx ; git submodule foreach --recursive git clean -xffd" >&2
3943
exit 1
4044
fi

pkg/acceptance/compose/gss/psql/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# Build the test binary in a multistage build.
2-
FROM golang:1.23 AS builder
2+
# We use a docker image mirror to avoid pulling from 3rd party repos, which sometimes have reliability issues.
3+
# See https://cockroachlabs.atlassian.net/wiki/spaces/devinf/pages/3462594561/Docker+image+sync for the details.
4+
FROM us-east1-docker.pkg.dev/crl-docker-sync/docker-io/library/golang:1.23 AS builder
35
WORKDIR /workspace
46
COPY . .
57
RUN go test -v -c -tags gss_compose -o gss.test

pkg/cmd/roachprod/docker/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ RUN bazel build --config=crosslinux //pkg/cmd/roachprod:roachprod
1212
# Copy the roachprod binary to a stable location
1313
RUN cp $(bazel info bazel-bin --config=crosslinux)/pkg/cmd/roachprod/roachprod_/roachprod ./
1414

15-
FROM golang:1.23
15+
# We use a docker image mirror to avoid pulling from 3rd party repos, which sometimes have reliability issues.
16+
# See https://cockroachlabs.atlassian.net/wiki/spaces/devinf/pages/3462594561/Docker+image+sync for the details.
17+
FROM us-east1-docker.pkg.dev/crl-docker-sync/docker-io/library/golang:1.23
1618
COPY entrypoint.sh build.sh /build/
1719
RUN ["/build/build.sh"]
1820
COPY --from=builder /build/roachprod /usr/local/bin/roachprod

0 commit comments

Comments
 (0)