[interop] Avoid installing the same python dependencies twice in Go 1.64 tests (#36864)

<!--

If you know who should review your pull request, please assign it to that
person, otherwise the pull request would get assigned randomly.

If your pull request is for a specific language, please add the appropriate
lang label.

-->

Avoid installing the same python dependencies twice due to duplication in template from https://github.com/grpc/grpc/pull/36755.

Redundant installation in the go1.x Dockerfile presently:
![image](https://github.com/grpc/grpc/assets/46515553/f8dafde9-5442-41b9-a429-dec93eee7c03)

Fixes: https://github.com/grpc/grpc/issues/36060

Closes #36864

PiperOrigin-RevId: 643048549
pull/36918/head
Arjan Singh Bal 6 months ago committed by Copybara-Service
parent d4b5e12f8e
commit a535a11efc
  1. 4
      templates/tools/dockerfile/run_tests_python_deps_venv.include
  2. 2
      tools/bazelify_tests/dockerimage_current_versions.bzl
  3. 2
      tools/dockerfile/interoptest/grpc_interop_go1.x.current_version
  4. 3
      tools/dockerfile/interoptest/grpc_interop_go1.x/Dockerfile

@ -26,8 +26,6 @@ RUN echo "source $PYTHON_ENV/bin/activate" >> ~/.bashrc
# but since our python2 usage is deprecated, we should get rid of it. # but since our python2 usage is deprecated, we should get rid of it.
RUN /bin/bash -c "source $PYTHON_ENV/bin/activate && \ RUN /bin/bash -c "source $PYTHON_ENV/bin/activate && \
python3 -m pip install --upgrade pip==19.3.1 && \ python3 -m pip install --upgrade pip==19.3.1 && \
python3 -m pip install six==1.16.0 && \ python3 -m pip install six==1.16.0"
python3 -m pip install --upgrade google-auth==1.23.0 google-api-python-client==1.12.8 oauth2client==4.1.0"
<%include file="./gcp_api_libraries_venv.include"/> <%include file="./gcp_api_libraries_venv.include"/>

@ -78,7 +78,7 @@ DOCKERIMAGE_CURRENT_VERSIONS = {
"tools/dockerfile/interoptest/grpc_interop_go1.16.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.16@sha256:3767f47c9d06584c6c07b7ab536e13f3e87550330e6c2652ad288d3a72b0de23", "tools/dockerfile/interoptest/grpc_interop_go1.16.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.16@sha256:3767f47c9d06584c6c07b7ab536e13f3e87550330e6c2652ad288d3a72b0de23",
"tools/dockerfile/interoptest/grpc_interop_go1.19.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.19@sha256:889e7ff34399a5e16af87940d1eaa239e56da307f7faca3f8f1d28379c2e3df3", "tools/dockerfile/interoptest/grpc_interop_go1.19.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.19@sha256:889e7ff34399a5e16af87940d1eaa239e56da307f7faca3f8f1d28379c2e3df3",
"tools/dockerfile/interoptest/grpc_interop_go1.8.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.8@sha256:7830a301b37539252c592b9cd7fa30a6142d0afc717a05fc8d2b82c74fb45efe", "tools/dockerfile/interoptest/grpc_interop_go1.8.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.8@sha256:7830a301b37539252c592b9cd7fa30a6142d0afc717a05fc8d2b82c74fb45efe",
"tools/dockerfile/interoptest/grpc_interop_go1.x.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.x@sha256:c1d1babd31ea7e635aa68d56803212f9e0091ff628288c18dc86d890f837303a", "tools/dockerfile/interoptest/grpc_interop_go1.x.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.x@sha256:9d02b61552a93770ebb022f588daf9acd1088d29197fe120e0b082ede73f4584",
"tools/dockerfile/interoptest/grpc_interop_http2.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_http2@sha256:e3f247d8038374848fadf7215b841e3575c0b2a4217feb503a79b8004b164c5a", "tools/dockerfile/interoptest/grpc_interop_http2.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_http2@sha256:e3f247d8038374848fadf7215b841e3575c0b2a4217feb503a79b8004b164c5a",
"tools/dockerfile/interoptest/grpc_interop_java.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_java@sha256:6c0319bbbf77d6c198f61adf92d205efd33cbd2cccaf914a1af8f2dcb61b16a1", "tools/dockerfile/interoptest/grpc_interop_java.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_java@sha256:6c0319bbbf77d6c198f61adf92d205efd33cbd2cccaf914a1af8f2dcb61b16a1",
"tools/dockerfile/interoptest/grpc_interop_node.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_node@sha256:549a7683cc024fb7ffee807eaa8acb6c2d5a5dd0184a2590f91852804eea39a4", "tools/dockerfile/interoptest/grpc_interop_node.current_version": "docker://us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_node@sha256:549a7683cc024fb7ffee807eaa8acb6c2d5a5dd0184a2590f91852804eea39a4",

@ -1 +1 @@
us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.x:9740f2234d8c996def3f0e09791328c39dac0ab1@sha256:c1d1babd31ea7e635aa68d56803212f9e0091ff628288c18dc86d890f837303a us-docker.pkg.dev/grpc-testing/testing-images-public/grpc_interop_go1.x:9a524415365a73162b7f463bf0409ca04f64a73c@sha256:9d02b61552a93770ebb022f588daf9acd1088d29197fe120e0b082ede73f4584

@ -43,8 +43,7 @@ RUN echo "source $PYTHON_ENV/bin/activate" >> ~/.bashrc
# use pinned version of pip to avoid sudden breakages # use pinned version of pip to avoid sudden breakages
# TODO(#36814): currently six is needed for tools/run_tests scripts # TODO(#36814): currently six is needed for tools/run_tests scripts
# but since our python2 usage is deprecated, we should get rid of it. # but since our python2 usage is deprecated, we should get rid of it.
RUN /bin/bash -c "source $PYTHON_ENV/bin/activate && python3 -m pip install --upgrade pip==19.3.1 && python3 -m pip install six==1.16.0 && python3 -m pip install --upgrade google-auth==1.23.0 google-api-python-client==1.12.8 oauth2client==4.1.0" RUN /bin/bash -c "source $PYTHON_ENV/bin/activate && python3 -m pip install --upgrade pip==19.3.1 && python3 -m pip install six==1.16.0"
# Install Google Cloud Platform API libraries # Install Google Cloud Platform API libraries
# These are needed for uploading test results to BigQuery (e.g. by tools/run_tests scripts) # These are needed for uploading test results to BigQuery (e.g. by tools/run_tests scripts)

Loading…
Cancel
Save