From c4e34452afeccdeb3c8b8f1f2d280f39a57fe0d1 Mon Sep 17 00:00:00 2001 From: Dror Prital <76714716+dprital@users.noreply.github.com> Date: Wed, 8 Mar 2023 13:41:41 +0200 Subject: [PATCH] [Mellanox] Install python2 on syncd (#14151) - Why I did it Some scripts on syncd require Python2 support. - How I did it Add Python2 to syncd docker - How to verify it Run manually python scripts under Nvidia SDK debug to ensure they are working --- platform/mellanox/docker-syncd-mlnx/Dockerfile.j2 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/platform/mellanox/docker-syncd-mlnx/Dockerfile.j2 b/platform/mellanox/docker-syncd-mlnx/Dockerfile.j2 index 63a20a1f5f..69bd6294fd 100755 --- a/platform/mellanox/docker-syncd-mlnx/Dockerfile.j2 +++ b/platform/mellanox/docker-syncd-mlnx/Dockerfile.j2 @@ -29,17 +29,20 @@ ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && \ apt-get install -y \ libxml2 \ + python-dev \ python3-pip \ python3-dev \ - python-is-python3 \ {%- if ENABLE_ASAN == "y" %} libasan6 \ {%- endif %} + python-setuptools \ python3-setuptools RUN pip3 install --upgrade pip RUN apt-get purge -y python-pip +RUN curl https://bootstrap.pypa.io/pip/2.7/get-pip.py --output get-pip.py + {% if docker_syncd_mlnx_debs.strip() -%} # Copy locally-built Debian package dependencies {{ copy_files("debs/", docker_syncd_mlnx_debs.split(' '), "/debs/") }}