fb14b987b4
#### Why I did it After k8s upgrade a container, k8s can only know the container is running, don't know the service's status inside container. So we need a probe inside container, k8s will call the probe to check whether the container is really ready. ##### Work item tracking - Microsoft ADO **(number only)**: 22453004 #### How I did it Add a health check probe inside config engine container, the probe will check whether the start service exit normally or not if the start service exists and call the python script to do container self-related specific checks if the script is there. The python script should be implemented by feature owner if it's needed. more details: [design doc](https://github.com/sonic-net/SONiC/blob/master/doc/kubernetes/health-check.md) #### How to verify it Check path /usr/bin/readiness_probe.sh inside container. #### Which release branch to backport (provide reason below if selected) - [ ] 201811 - [ ] 201911 - [ ] 202006 - [ ] 202012 - [ ] 202106 - [ ] 202111 - [x] 202205 - [x] 202211 #### Tested branch (Please provide the tested image version) - [x] 20220531.28
36 lines
1.3 KiB
Makefile
36 lines
1.3 KiB
Makefile
# sonic-ctrmgrd package
|
|
|
|
SONIC_CTRMGRD = sonic_ctrmgrd-1.0.0-py3-none-any.whl
|
|
$(SONIC_CTRMGRD)_SRC_PATH = $(SRC_PATH)/sonic-ctrmgrd
|
|
$(SONIC_CTRMGRD)_FILES_PATH = $($(SONIC_CTRMGRD)_SRC_PATH)/ctrmgr
|
|
|
|
$(SONIC_CTRMGRD)_PYTHON_VERSION = 3
|
|
$(SONIC_CTRMGRD)_DEBS_DEPENDS += $(PYTHON3_SWSSCOMMON)
|
|
$(SONIC_CTRMGRD)_DEPENDS += $(SONIC_PY_COMMON_PY3)
|
|
|
|
$(SONIC_CTRMGRD)_CONTAINER_SCRIPT = container
|
|
$($(SONIC_CTRMGRD)_CONTAINER_SCRIPT)_PATH = $($(SONIC_CTRMGRD)_FILES_PATH)
|
|
|
|
$(SONIC_CTRMGRD)_STARTUP_SCRIPT = container_startup.py
|
|
$($(SONIC_CTRMGRD)_STARTUP_SCRIPT)_PATH = $($(SONIC_CTRMGRD)_FILES_PATH)
|
|
|
|
$(SONIC_CTRMGRD)_CFG_JSON = remote_ctr.config.json
|
|
$($(SONIC_CTRMGRD)_CFG_JSON)_PATH = $($(SONIC_CTRMGRD)_FILES_PATH)
|
|
|
|
$(SONIC_CTRMGRD)_SERVICE = ctrmgrd.service
|
|
$($(SONIC_CTRMGRD)_SERVICE)_PATH = $($(SONIC_CTRMGRD)_FILES_PATH)
|
|
|
|
$(SONIC_CTRMGRD)_HEALTH_PROBE = readiness_probe.sh
|
|
$($(SONIC_CTRMGRD)_HEALTH_PROBE)_PATH = $($(SONIC_CTRMGRD)_FILES_PATH)
|
|
|
|
SONIC_PYTHON_WHEELS += $(SONIC_CTRMGRD)
|
|
|
|
$(SONIC_CTRMGRD)_FILES = $($(SONIC_CTRMGRD)_CONTAINER_SCRIPT)
|
|
$(SONIC_CTRMGRD)_FILES += $($(SONIC_CTRMGRD)_STARTUP_SCRIPT)
|
|
$(SONIC_CTRMGRD)_FILES += $($(SONIC_CTRMGRD)_CFG_JSON)
|
|
$(SONIC_CTRMGRD)_FILES += $($(SONIC_CTRMGRD)_SERVICE)
|
|
$(SONIC_CTRMGRD)_FILES += $($(SONIC_CTRMGRD)_HEALTH_PROBE)
|
|
|
|
SONIC_COPY_FILES += $($(SONIC_CTRMGRD)_FILES)
|
|
|