Don't use gcr.io/bazel-public/testing (#2876)
We should use the same images in the testing BK org as in the prod BK
orgs.
diff --git a/buildkite/bazelci.py b/buildkite/bazelci.py
index deb7a2b..52e263e 100755
--- a/buildkite/bazelci.py
+++ b/buildkite/bazelci.py
@@ -327,11 +327,6 @@
"bazel": DOWNSTREAM_PROJECTS_PRODUCTION,
}[BUILDKITE_ORG]
-DOCKER_REGISTRY_PREFIX = {
- "bazel-testing": "bazel-public/testing",
- "bazel-trusted": "bazel-public",
- "bazel": "bazel-public",
-}[BUILDKITE_ORG]
# Platforms we no longer support, but still exist in the artifact registry.
# NOTE: These names are the ones use din the PLATFORMS dict, not the
@@ -427,8 +422,6 @@
def get_docker_image(image_name, is_arm64=False):
- if THIS_IS_TESTING:
- return f"gcr.io/{DOCKER_REGISTRY_PREFIX}/{image_name}"
digests = IMAGE_HASHES.get(image_name)
if not digests:
raise ValueError(f"No digest found for docker image: {image_name}")
@@ -436,7 +429,7 @@
digest = digests.get(arch)
if not digest:
raise ValueError(f"No {arch} digest found for docker image: {image_name}")
- return f"gcr.io/{DOCKER_REGISTRY_PREFIX}/{image_name}@{digest}"
+ return f"gcr.io/bazel-public/{image_name}@{digest}"
# A map containing all supported platform names as keys, with the values being
diff --git a/buildkite/docker/build.sh b/buildkite/docker/build.sh
index 2c21416..62f1bf6 100755
--- a/buildkite/docker/build.sh
+++ b/buildkite/docker/build.sh
@@ -2,17 +2,7 @@
set -euxo pipefail
-case $(git symbolic-ref --short HEAD) in
- master)
- PREFIX="bazel-public"
- ;;
- testing)
- PREFIX="bazel-public/testing"
- ;;
- *)
- echo "You must build Docker images either from the master or the testing branch!"
- exit 1
-esac
+PREFIX=bazel-public
# Enable use of buildkit for all builds. No extra support in the Dockerfile is required.
# See https://docs.docker.com/develop/develop-images/build_enhancements/ for details.
diff --git a/buildkite/docker/push.sh b/buildkite/docker/push.sh
index 323b725..8ccff49 100755
--- a/buildkite/docker/push.sh
+++ b/buildkite/docker/push.sh
@@ -1,18 +1,7 @@
#!/bin/bash
set -euxo pipefail
-
-case $(git symbolic-ref --short HEAD) in
- master)
- PREFIX="bazel-public"
- ;;
- testing)
- PREFIX="bazel-public/testing"
- ;;
- *)
- echo "You must build Docker images either from the master or the testing branch!"
- exit 1
-esac
+PREFIX=bazel-public
# Containers used by Bazel CI
docker push "gcr.io/$PREFIX/rockylinux8" &