[lldp]: Lldp docker to use python3 version of sonic-db-syncd package. (#6046)

Made changes so that Lldp docker start using py3 of sonic-db-syncd

submodule update sonic-db-syncd
5cc29a1b32d8d1f4dfbc967bfea2727c50a49c76 (HEAD -> master, origin/master, origin/HEAD) Changes to convert sonic-dbsyncd from python 2 to 3

Signed-off-by: Abhishek Dosi <abdosi@microsoft.com>
This commit is contained in:
abdosi 2020-11-30 10:44:40 -08:00 committed by GitHub
parent d475b96aa3
commit 872c85d8e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 23 additions and 5 deletions

View File

@ -8,7 +8,7 @@
check program lldp|lldpd_monitor with path "/usr/bin/process_checker lldp lldpd:" check program lldp|lldpd_monitor with path "/usr/bin/process_checker lldp lldpd:"
if status != 0 for 5 times within 5 cycles then alert repeat every 1 cycles if status != 0 for 5 times within 5 cycles then alert repeat every 1 cycles
check program lldp|lldp_syncd with path "/usr/bin/process_checker lldp python2 -m lldp_syncd" check program lldp|lldp_syncd with path "/usr/bin/process_checker lldp python3 -m lldp_syncd"
if status != 0 for 5 times within 5 cycles then alert repeat every 1 cycles if status != 0 for 5 times within 5 cycles then alert repeat every 1 cycles
check program lldp|lldpmgrd with path "/usr/bin/process_checker lldp python3 /usr/bin/lldpmgrd" check program lldp|lldpmgrd with path "/usr/bin/process_checker lldp python3 /usr/bin/lldpmgrd"

View File

@ -69,7 +69,7 @@ dependent_startup=true
dependent_startup_wait_for=lldpd:running dependent_startup_wait_for=lldpd:running
[program:lldp-syncd] [program:lldp-syncd]
command=/usr/bin/env python2 -m lldp_syncd command=/usr/bin/env python3 -m lldp_syncd
priority=4 priority=4
autostart=false autostart=false
autorestart=false autorestart=false

11
rules/dbsyncd-py3.dep Normal file
View File

@ -0,0 +1,11 @@
SPATH := $($(DBSYNCD_PY3)_SRC_PATH)
DEP_FILES := $(SONIC_COMMON_FILES_LIST) rules/dbsyncd-py3.mk rules/dbsyncd-py3.dep
DEP_FILES += $(SONIC_COMMON_BASE_FILES_LIST)
SMDEP_FILES := $(addprefix $(SPATH)/,$(shell cd $(SPATH) && git ls-files))
$(DBSYNCD_PY3)_CACHE_MODE := GIT_CONTENT_SHA
$(DBSYNCD_PY3)_DEP_FLAGS := $(SONIC_COMMON_FLAGS_LIST)
$(DBSYNCD_PY3)_DEP_FILES := $(DEP_FILES)
$(DBSYNCD_PY3)_SMDEP_FILES := $(SMDEP_FILES)
$(DBSYNCD_PY3)_SMDEP_PATHS := $(SPATH)

7
rules/dbsyncd-py3.mk Normal file
View File

@ -0,0 +1,7 @@
# sonic-dbsyncd python3 wheel
DBSYNCD_PY3 = sonic_d-2.0.0-py3-none-any.whl
$(DBSYNCD_PY3)_SRC_PATH = $(SRC_PATH)/sonic-dbsyncd
$(DBSYNCD_PY3)_PYTHON_VERSION = 3
$(DBSYNCD_PY3)_DEPENDS += $(SWSSSDK_PY3)
SONIC_PYTHON_WHEELS += $(DBSYNCD_PY3)

View File

@ -6,14 +6,14 @@ DOCKER_LLDP_DBG = $(DOCKER_LLDP_STEM)-$(DBG_IMAGE_MARK).gz
$(DOCKER_LLDP)_PATH = $(DOCKERS_PATH)/docker-lldp $(DOCKER_LLDP)_PATH = $(DOCKERS_PATH)/docker-lldp
$(DOCKER_LLDP)_DEPENDS += $(LLDPD) $(LIBSWSSCOMMON) $(PYTHON_SWSSCOMMON) $(PYTHON3_SWSSCOMMON) $(DOCKER_LLDP)_DEPENDS += $(LLDPD) $(LIBSWSSCOMMON) $(PYTHON3_SWSSCOMMON)
$(DOCKER_LLDP)_DBG_DEPENDS = $($(DOCKER_CONFIG_ENGINE_BUSTER)_DBG_DEPENDS) $(DOCKER_LLDP)_DBG_DEPENDS = $($(DOCKER_CONFIG_ENGINE_BUSTER)_DBG_DEPENDS)
$(DOCKER_LLDP)_DBG_DEPENDS += $(LLDPD_DBG) $(LIBSWSSCOMMON_DBG) $(DOCKER_LLDP)_DBG_DEPENDS += $(LLDPD_DBG) $(LIBSWSSCOMMON_DBG)
$(DOCKER_LLDP)_DBG_IMAGE_PACKAGES = $($(DOCKER_CONFIG_ENGINE_BUSTER)_DBG_IMAGE_PACKAGES) $(DOCKER_LLDP)_DBG_IMAGE_PACKAGES = $($(DOCKER_CONFIG_ENGINE_BUSTER)_DBG_IMAGE_PACKAGES)
$(DOCKER_LLDP)_PYTHON_WHEELS += $(DBSYNCD_PY2) $(DOCKER_LLDP)_PYTHON_WHEELS += $(DBSYNCD_PY3)
$(DOCKER_LLDP)_LOAD_DOCKERS += $(DOCKER_CONFIG_ENGINE_BUSTER) $(DOCKER_LLDP)_LOAD_DOCKERS += $(DOCKER_CONFIG_ENGINE_BUSTER)
SONIC_DOCKER_IMAGES += $(DOCKER_LLDP) SONIC_DOCKER_IMAGES += $(DOCKER_LLDP)

@ -1 +1 @@
Subproject commit 95824a9a4b0c2be3351f6a93f3f55327d10113c0 Subproject commit 5cc29a1b32d8d1f4dfbc967bfea2727c50a49c76