From 7adb836490533bbbafe97f2afaf74787f86d8981 Mon Sep 17 00:00:00 2001 From: cobalt-github-releaser-bot <95661244+cobalt-github-releaser-bot@users.noreply.github.com> Date: Mon, 23 Sep 2024 12:34:06 -0700 Subject: [PATCH] Cherry pick PR #4141: [Docker] Fix base container alias (#4142) Refer to the original PR: https://github.com/youtube/cobalt/pull/4141 Switches the container base image url to a supported alias. b/369130578 --------- Co-authored-by: Kaido Kert --- .github/actions/docker/action.yaml | 5 ++++- cobalt/site/docker/Dockerfile | 2 +- docker-compose.yml | 2 +- docker/linux/base/Dockerfile | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/actions/docker/action.yaml b/.github/actions/docker/action.yaml index 2880521fd45e..d32282f52506 100644 --- a/.github/actions/docker/action.yaml +++ b/.github/actions/docker/action.yaml @@ -61,8 +61,11 @@ runs: echo "DOCKER_TAG=${docker_tag}" >> $GITHUB_ENV shell: bash - name: Set up Cloud SDK - if: ${{ (steps.changed-files.outputs.any_changed == 'true') && (github.event_name == 'pull_request') && (github.event.pull_request.head.repo.fork) }} uses: isarkis/setup-gcloud@40dce7857b354839efac498d3632050f568090b6 # v1.1.1 + - name: Configure Docker auth for GCloud + shell: bash + run: | + gcloud auth configure-docker - name: Set Docker Tag id: set-docker-tag-presubmit-fork env: diff --git a/cobalt/site/docker/Dockerfile b/cobalt/site/docker/Dockerfile index 1acba94d9995..90bd6358e18d 100644 --- a/cobalt/site/docker/Dockerfile +++ b/cobalt/site/docker/Dockerfile @@ -13,7 +13,7 @@ # limitations under the License. ARG FROM_IMAGE -FROM ${FROM_IMAGE:-gcr.io/cloud-marketplace-containers/google/debian11} +FROM ${FROM_IMAGE:-marketplace.gcr.io/google/debian11:latest} RUN apt update -qqy \ && apt install -qqy --no-install-recommends \ diff --git a/docker-compose.yml b/docker-compose.yml index 775b90a0c373..cf63a616085d 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -98,7 +98,7 @@ services: base-bionic: build: args: - - BASE_OS=gcr.io/cloud-marketplace-containers/google/ubuntu1804 + - BASE_OS=marketplace.gcr.io/google/ubuntu1804 - BASE_OS_TAG=latest context: ./docker/linux dockerfile: base/Dockerfile diff --git a/docker/linux/base/Dockerfile b/docker/linux/base/Dockerfile index 16f060aec3aa..66bb1f5e8998 100644 --- a/docker/linux/base/Dockerfile +++ b/docker/linux/base/Dockerfile @@ -14,7 +14,7 @@ ARG BASE_OS ARG BASE_OS_TAG -FROM ${BASE_OS:-gcr.io/cloud-marketplace-containers/google/debian11}:${BASE_OS_TAG:-latest} +FROM ${BASE_OS:-marketplace.gcr.io/google/debian11}:${BASE_OS_TAG:-latest} COPY base/clean-after-apt.sh /opt/clean-after-apt.sh