Skip to content

Commit dde00b6

Browse files
authored
xds/interop: add gke TD resource cleanup to daily cleanup script (grpc#28370)
1 parent ecf6a7f commit dde00b6

File tree

7 files changed

+385
-210
lines changed

7 files changed

+385
-210
lines changed

tools/gcp/utils/cleanup_xds_resources.py

-202
This file was deleted.

tools/gcp/utils/keep_xds_interop_resources.json

-6
This file was deleted.

tools/internal_ci/linux/grpc_xds_resource_cleanup.sh

+19-2
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,22 @@ set -ex
1818
cd "$(dirname "$0")/../../.."
1919

2020
pyenv local 3.6.1
21-
python3 -m pip install dataclasses
22-
python3 tools/gcp/utils/cleanup_xds_resources.py
21+
gcloud container clusters get-credentials interop-test-psm-sec-v2-us-central1-a --zone us-central1-a --project grpc-testing
22+
23+
cd tools/run_tests/xds_k8s_test_driver
24+
python3 -m pip install -r requirements.txt
25+
26+
python3 -m grpc_tools.protoc --proto_path=../../../ \
27+
--python_out=. --grpc_python_out=. \
28+
src/proto/grpc/testing/empty.proto \
29+
src/proto/grpc/testing/messages.proto \
30+
src/proto/grpc/testing/test.proto
31+
32+
# flag resource_prefix is required by the gke test framework, but doesn't
33+
# matter for the cleanup script.
34+
python3 -m bin.cleanup.cleanup \
35+
--project=grpc-testing \
36+
--network=default-vpc \
37+
--kube_context=gke_grpc-testing_us-central1-a_interop-test-psm-sec-v2-us-central1-a \
38+
--resource_prefix='required-but-does-not-matter' \
39+
--td_bootstrap_image='required-but-does-not-matter' --server_image='required-but-does-not-matter' --client_image='required-but-does-not-matter'
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# This folder contains scripts to delete leaked resources from test runs
2+

0 commit comments

Comments
 (0)