This is an automated email from the ASF dual-hosted git repository.
damondouglas pushed a commit to branch fix-distroless-wfs
in repository https://gitbox.apache.org/repos/asf/beam.git
The following commit(s) were added to refs/heads/fix-distroless-wfs by this
push:
new 7619842e43f Update run_validatescontainer.sh env variables
7619842e43f is described below
commit 7619842e43fd822a43ec06cea6d640c3ed118a46
Author: Damon <[email protected]>
AuthorDate: Thu Jan 16 13:21:56 2025 -0800
Update run_validatescontainer.sh env variables
---
sdks/python/container/run_validatescontainer.sh | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/sdks/python/container/run_validatescontainer.sh
b/sdks/python/container/run_validatescontainer.sh
index 6570953ea8d..c587740a4a7 100755
--- a/sdks/python/container/run_validatescontainer.sh
+++ b/sdks/python/container/run_validatescontainer.sh
@@ -22,7 +22,8 @@
# GCS_LOCATION -> Temporary location to use for service tests.
# PROJECT -> Project name to use for dataflow and docker images.
# REGION -> Region name to use for Dataflow
-# TEST_NAME -> Test to execute; defaults to 'it_validatescontainer'.
+# TEST_MARK -> Test marker configured in sdks/python/pytest.ini to execute;
defaults to 'it_validatescontainer'.
+# IMAGE_SUFFIX -> Suffix to apply to container image name (optional).
#
# Execute from the root of the repository:
# test Python3.8 x86 container:
@@ -61,7 +62,7 @@ IMAGE_NAME="${IMAGE_PREFIX}python${PY_VERSION}_sdk"
CONTAINER_PROJECT="sdks:python:container:py${PY_VERSION//.}" # Note: we
substitute away the dot in the version.
PY_INTERPRETER="python${PY_VERSION}"
MACHINE_TYPE_ARGS=""
-TEST_NAME=${TEST_NAME:-it_validatescontainer}
+TEST_MARK=${TEST_MARK:-it_validatescontainer}
XUNIT_FILE="pytest-$IMAGE_NAME.xml"
@@ -76,7 +77,7 @@ gcloud -v
TAG=$(date +%Y%m%d-%H%M%S%N)
CONTAINER=us.gcr.io/$PROJECT/$USER/$IMAGE_NAME
-PREBUILD_SDK_CONTAINER_REGISTRY_PATH=us.gcr.io/$PROJECT/$USER/prebuild_python${PY_VERSION//.}_sdk
+PREBUILD_SDK_CONTAINER_REGISTRY_PATH=us.gcr.io/$PROJECT/$USER/prebuild_python${PY_VERSION//.}_sdk${IMAGE_SUFFIX}
echo "Using container $CONTAINER"
echo "Using CPU architecture $ARCH"
@@ -110,8 +111,8 @@ function cleanup_container {
if [[ "$ARCH" == "x86" ]]; then
gcloud --quiet container images delete $CONTAINER:$TAG || echo "Failed to
delete container"
fi
- for digest in $(gcloud container images list-tags
$PREBUILD_SDK_CONTAINER_REGISTRY_PATH/beam_python_prebuilt_sdk
--format="get(digest)")
- do gcloud container images delete
$PREBUILD_SDK_CONTAINER_REGISTRY_PATH/beam_python_prebuilt_sdk@$digest
--force-delete-tags --quiet || echo "Failed to remove prebuilt sdk container
image"
+ for digest in $(gcloud container images list-tags
$PREBUILD_SDK_CONTAINER_REGISTRY_PATH/beam_python_prebuilt_sdk${IMAGE_SUFFIX}
--format="get(digest)")
+ do gcloud container images delete
$PREBUILD_SDK_CONTAINER_REGISTRY_PATH/beam_python_prebuilt_sdk${IMAGE_SUFFIX}@$digest
--force-delete-tags --quiet || echo "Failed to remove prebuilt sdk container
image"
done
echo "Removed the container"