Skip to content

Commit accf5b3

Browse files
Integrate DASH API into build system (#21553)
Integrate DASH API into build system
1 parent 06a657c commit accf5b3

File tree

3 files changed

+4
-12
lines changed

3 files changed

+4
-12
lines changed

dockers/docker-sonic-mgmt/Dockerfile.j2

+2-10
Original file line numberDiff line numberDiff line change
@@ -210,9 +210,9 @@ RUN mkdir -p /etc/apt/keyrings \
210210
&& apt-get update && apt-get install -y azure-cli
211211

212212
## Copy and install sonic-mgmt docker dependencies
213-
COPY debs/sonic-device-data_*.deb debs/
213+
COPY debs/sonic-device-data_*.deb debs/libdashapi_*.deb debs/
214214

215-
RUN dpkg -i debs/sonic-device-data_*.deb
215+
RUN dpkg -i debs/sonic-device-data_*.deb debs/libdashapi_*.deb
216216

217217
# Install protobuf 3.21.12 which is from https://deb.debian.org/debian/pool/main/p/protobuf/protobuf_3.21.12-3.dsc
218218
RUN mkdir -p /tmp/protobuf \
@@ -227,14 +227,6 @@ RUN mkdir -p /tmp/protobuf \
227227
&& dpkg -i *.deb \
228228
&& rm -rf /tmp/protobuf
229229

230-
# Install dash-api
231-
RUN cd /tmp \
232-
&& mkdir -p /usr/lib/python3/dist-packages/dash_api \
233-
&& wget https://raw.githubusercontent.com/sonic-net/sonic-dash-api/master/misc/pypkg/dash_api/__init__.py -O /usr/lib/python3/dist-packages/dash_api/__init__.py \
234-
&& git clone https://github.com/sonic-net/sonic-dash-api.git \
235-
&& protoc -I=sonic-dash-api/proto --python_out=/usr/lib/python3/dist-packages/dash_api sonic-dash-api/proto/*.proto \
236-
&& rm -rf /tmp/sonic-dash-api
237-
238230
RUN mkdir /var/run/sshd
239231
EXPOSE 22
240232

rules/docker-orchagent.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ DOCKER_ORCHAGENT_STEM = docker-orchagent
44
DOCKER_ORCHAGENT = $(DOCKER_ORCHAGENT_STEM).gz
55
DOCKER_ORCHAGENT_DBG = $(DOCKER_ORCHAGENT_STEM)-$(DBG_IMAGE_MARK).gz
66

7-
$(DOCKER_ORCHAGENT)_DEPENDS += $(SWSS) $(SONIC_RSYSLOG_PLUGIN)
7+
$(DOCKER_ORCHAGENT)_DEPENDS += $(SWSS) $(SONIC_RSYSLOG_PLUGIN) $(LIB_SONIC_DASH_API)
88

99
ifeq ($(ENABLE_ASAN), y)
1010
$(DOCKER_ORCHAGENT)_DEPENDS += $(SWSS_DBG)

rules/docker-sonic-mgmt.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# docker image for sonic-mgmt
22
DOCKER_SONIC_MGMT = docker-sonic-mgmt.gz
33
$(DOCKER_SONIC_MGMT)_PATH = $(DOCKERS_PATH)/docker-sonic-mgmt
4-
$(DOCKER_SONIC_MGMT)_DEPENDS += $(SONIC_DEVICE_DATA) $(PTF)
4+
$(DOCKER_SONIC_MGMT)_DEPENDS += $(SONIC_DEVICE_DATA) $(PTF) $(LIB_SONIC_DASH_API)
55
SONIC_DOCKER_IMAGES += $(DOCKER_SONIC_MGMT)
66
SONIC_BULLSEYE_DOCKERS += $(DOCKER_SONIC_MGMT)

0 commit comments

Comments
 (0)