[pmon]: Install vanilla 'thrift' Python 2 and 3 packages for Barefoot in host and PMon (#6080)
Barefoot platform vendors' sonic_platform packages import the Python 'thrift' library. Previously, our custom-built package was being installed in the PMon container and host OS. However, we are only building a Python 2 version of that package, which was only intended for use with saithrift. Fixes #6077
This commit is contained in:
parent
03287cdbd7
commit
83f0d8240e
@ -32,6 +32,10 @@ RUN apt-get update && \
|
||||
# cause conflicts.
|
||||
RUN pip2 install enum34
|
||||
|
||||
# Barefoot platform vendors' sonic_platform packages import the Python 'thrift' library
|
||||
RUN pip2 install thrift==0.13.0
|
||||
RUN pip3 install thrift==0.13.0
|
||||
|
||||
{% if docker_platform_monitor_debs.strip() -%}
|
||||
# Copy locally-built Debian package dependencies
|
||||
{{ copy_files("debs/", docker_platform_monitor_debs.split(' '), "/debs/") }}
|
||||
|
@ -217,6 +217,12 @@ sudo cp {{platform_common_py3_wheel_path}} $FILESYSTEM_ROOT/$PLATFORM_COMMON_PY3
|
||||
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip3 install $PLATFORM_COMMON_PY3_WHEEL_NAME
|
||||
sudo rm -rf $FILESYSTEM_ROOT/$PLATFORM_COMMON_PY3_WHEEL_NAME
|
||||
|
||||
{# Barefoot platform vendors' sonic_platform packages import the Python 'thrift' library #}
|
||||
{% if sonic_asic_platform == "barefoot" %}
|
||||
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip2 install thrift==0.13.0
|
||||
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip3 install thrift==0.13.0
|
||||
{% endif %}
|
||||
|
||||
# Install prerequisites needed for installing the Python m2crypto package, used by sonic-utilities
|
||||
# These packages can be uninstalled after intallation
|
||||
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y install build-essential libssl-dev swig
|
||||
|
@ -3,7 +3,7 @@
|
||||
SONIC_ONE_IMAGE = sonic-barefoot.bin
|
||||
$(SONIC_ONE_IMAGE)_MACHINE = barefoot
|
||||
$(SONIC_ONE_IMAGE)_IMAGE_TYPE = onie
|
||||
$(SONIC_ONE_IMAGE)_INSTALLS += $(BFN_MODULE) $(PYTHON_THRIFT)
|
||||
$(SONIC_ONE_IMAGE)_INSTALLS += $(BFN_MODULE)
|
||||
$(SONIC_ONE_IMAGE)_INSTALLS += $(SYSTEMD_SONIC_GENERATOR)
|
||||
$(SONIC_ONE_IMAGE)_LAZY_INSTALLS += $(BFN_PLATFORM_MODULE)
|
||||
$(SONIC_ONE_IMAGE)_LAZY_INSTALLS += $(BFN_MONTARA_PLATFORM_MODULE)
|
||||
|
@ -7,9 +7,6 @@ DOCKER_PLATFORM_MONITOR_DBG = $(DOCKER_PLATFORM_MONITOR_STEM)-$(DBG_IMAGE_MARK).
|
||||
$(DOCKER_PLATFORM_MONITOR)_PATH = $(DOCKERS_PATH)/$(DOCKER_PLATFORM_MONITOR_STEM)
|
||||
|
||||
$(DOCKER_PLATFORM_MONITOR)_DEPENDS += $(LIBSENSORS) $(LM_SENSORS) $(FANCONTROL) $(SENSORD) $(LIBSWSSCOMMON) $(PYTHON_SWSSCOMMON) $(SMARTMONTOOLS)
|
||||
ifeq ($(CONFIGURED_PLATFORM),barefoot)
|
||||
$(DOCKER_PLATFORM_MONITOR)_DEPENDS += $(PYTHON_THRIFT)
|
||||
endif
|
||||
$(DOCKER_PLATFORM_MONITOR)_PYTHON_WHEELS += $(SONIC_PLATFORM_COMMON_PY2)
|
||||
$(DOCKER_PLATFORM_MONITOR)_PYTHON_WHEELS += $(SONIC_PLATFORM_COMMON_PY3)
|
||||
$(DOCKER_PLATFORM_MONITOR)_PYTHON_WHEELS += $(SWSSSDK_PY2)
|
||||
|
Loading…
Reference in New Issue
Block a user