From 05eddad228e12d24f66d61e47e774f311a878e7e Mon Sep 17 00:00:00 2001 From: Sergii Tkachenko Date: Mon, 8 Apr 2024 12:52:42 -0700 Subject: [PATCH 1/3] test/kokoro: Migrate PSM Interop to Artifact Registry Migrate PSM Interop images from Container Registry (gcr.io) to Artifact Registry (pkg.dev). RELEASE NOTES: n/a --- test/kokoro/psm-security.sh | 4 ++-- test/kokoro/xds_k8s_lb.sh | 4 ++-- test/kokoro/xds_url_map.sh | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/kokoro/psm-security.sh b/test/kokoro/psm-security.sh index 06c175f8b287..3976bb3b95a1 100755 --- a/test/kokoro/psm-security.sh +++ b/test/kokoro/psm-security.sh @@ -19,8 +19,8 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test server/client Docker images -readonly SERVER_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/go-server" -readonly CLIENT_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/go-client" +readonly SERVER_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-server" +readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" ####################################### diff --git a/test/kokoro/xds_k8s_lb.sh b/test/kokoro/xds_k8s_lb.sh index e43b6819c263..29e8ed03dc2e 100755 --- a/test/kokoro/xds_k8s_lb.sh +++ b/test/kokoro/xds_k8s_lb.sh @@ -19,8 +19,8 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test server/client Docker images -readonly SERVER_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/go-server" -readonly CLIENT_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/go-client" +readonly SERVER_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-server" +readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" ####################################### diff --git a/test/kokoro/xds_url_map.sh b/test/kokoro/xds_url_map.sh index 1c7b62db5fa4..ba91db5cdf0a 100755 --- a/test/kokoro/xds_url_map.sh +++ b/test/kokoro/xds_url_map.sh @@ -19,7 +19,7 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test client Docker images -readonly CLIENT_IMAGE_NAME="gcr.io/grpc-testing/xds-interop/go-client" +readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" ####################################### From 7c1ac60a78167ec9246c0e6dd163ae72ac2dba4b Mon Sep 17 00:00:00 2001 From: Sergii Tkachenko Date: Mon, 8 Apr 2024 14:23:20 -0700 Subject: [PATCH 2/3] Configure artifact registry auth --- test/kokoro/psm-security.sh | 2 +- test/kokoro/xds_k8s_lb.sh | 3 ++- test/kokoro/xds_url_map.sh | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/test/kokoro/psm-security.sh b/test/kokoro/psm-security.sh index 3976bb3b95a1..a4c4f9e6a9ee 100755 --- a/test/kokoro/psm-security.sh +++ b/test/kokoro/psm-security.sh @@ -39,7 +39,7 @@ build_test_app_docker_images() { echo "Building Go xDS interop test app Docker images" docker build -f "${SRC_DIR}/interop/xds/client/Dockerfile" -t "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}" docker build -f "${SRC_DIR}/interop/xds/server/Dockerfile" -t "${SERVER_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}" - gcloud -q auth configure-docker + gcloud -q auth configure-docker "${DOCKER_REGISTRY}" docker push "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" docker push "${SERVER_IMAGE_NAME}:${GIT_COMMIT}" if is_version_branch "${TESTING_VERSION}"; then diff --git a/test/kokoro/xds_k8s_lb.sh b/test/kokoro/xds_k8s_lb.sh index 29e8ed03dc2e..530a6d1de1cc 100755 --- a/test/kokoro/xds_k8s_lb.sh +++ b/test/kokoro/xds_k8s_lb.sh @@ -19,6 +19,7 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test server/client Docker images +readonly DOCKER_REGISTRY="us-docker.pkg.dev" readonly SERVER_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-server" readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" @@ -39,7 +40,7 @@ build_test_app_docker_images() { echo "Building Go xDS interop test app Docker images" docker build -f "${SRC_DIR}/interop/xds/client/Dockerfile" -t "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}" docker build -f "${SRC_DIR}/interop/xds/server/Dockerfile" -t "${SERVER_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}" - gcloud -q auth configure-docker + gcloud -q auth configure-docker "${DOCKER_REGISTRY}" docker push "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" docker push "${SERVER_IMAGE_NAME}:${GIT_COMMIT}" if is_version_branch "${TESTING_VERSION}"; then diff --git a/test/kokoro/xds_url_map.sh b/test/kokoro/xds_url_map.sh index ba91db5cdf0a..04ebdd43e041 100755 --- a/test/kokoro/xds_url_map.sh +++ b/test/kokoro/xds_url_map.sh @@ -35,7 +35,7 @@ readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" build_test_app_docker_images() { echo "Building Go xDS interop test app Docker images" docker build -f "${SRC_DIR}/interop/xds/client/Dockerfile" -t "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" "${SRC_DIR}" - gcloud -q auth configure-docker + gcloud -q auth configure-docker "${DOCKER_REGISTRY}" docker push "${CLIENT_IMAGE_NAME}:${GIT_COMMIT}" if is_version_branch "${TESTING_VERSION}"; then tag_and_push_docker_image "${CLIENT_IMAGE_NAME}" "${GIT_COMMIT}" "${TESTING_VERSION}" From 9edad573a0c0158ca6409b4b496707374ca041cc Mon Sep 17 00:00:00 2001 From: Sergii Tkachenko Date: Mon, 8 Apr 2024 15:25:31 -0700 Subject: [PATCH 3/3] Set DOCKER_REGISTRY in the rest of the buildscripts --- test/kokoro/psm-security.sh | 1 + test/kokoro/xds_url_map.sh | 1 + 2 files changed, 2 insertions(+) diff --git a/test/kokoro/psm-security.sh b/test/kokoro/psm-security.sh index a4c4f9e6a9ee..9df1e9bebf19 100755 --- a/test/kokoro/psm-security.sh +++ b/test/kokoro/psm-security.sh @@ -19,6 +19,7 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test server/client Docker images +readonly DOCKER_REGISTRY="us-docker.pkg.dev" readonly SERVER_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-server" readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}" diff --git a/test/kokoro/xds_url_map.sh b/test/kokoro/xds_url_map.sh index 04ebdd43e041..ce21728a2d8d 100755 --- a/test/kokoro/xds_url_map.sh +++ b/test/kokoro/xds_url_map.sh @@ -19,6 +19,7 @@ set -eo pipefail readonly GITHUB_REPOSITORY_NAME="grpc-go" readonly TEST_DRIVER_INSTALL_SCRIPT_URL="https://raw.githubusercontent.com/${TEST_DRIVER_REPO_OWNER:-grpc}/psm-interop/${TEST_DRIVER_BRANCH:-main}/.kokoro/psm_interop_kokoro_lib.sh" ## xDS test client Docker images +readonly DOCKER_REGISTRY="us-docker.pkg.dev" readonly CLIENT_IMAGE_NAME="us-docker.pkg.dev/grpc-testing/psm-interop/go-client" readonly FORCE_IMAGE_BUILD="${FORCE_IMAGE_BUILD:-0}"