In come cases we need YANG files which are converted from SNMP MIBs using smidump. For the Docker images we'll clone the from an external repository.

This commit is contained in:
Kristofer Hallin 2022-05-04 07:55:24 -07:00 committed by Olof hagsand
parent df687f7180
commit 7bdc5045b2

View file

@ -91,7 +91,7 @@ WORKDIR /clixon/clixon
COPY clixon . COPY clixon .
# Configure, build and install clixon # Configure, build and install clixon
RUN ./configure --prefix=/clixon/build --with-cligen=/clixon/build --with-restconf=native --enable-nghttp2 --enable-http1 --with-yang-standard-dir=/usr/local/share/yang/standard --enable-netsnmp RUN ./configure --prefix=/clixon/build --with-cligen=/clixon/build --with-restconf=native --enable-nghttp2 --enable-http1 --with-yang-standard-dir=/usr/local/share/yang/standard --enable-netsnmp --with-mib-generated-yang-dir=/usr/local/share/mib-yangs/
RUN make RUN make
RUN make install RUN make install
@ -119,6 +119,9 @@ WORKDIR /clixon
COPY startsystem_native.sh startsystem.sh COPY startsystem_native.sh startsystem.sh
RUN install startsystem.sh /clixon/build/bin/ RUN install startsystem.sh /clixon/build/bin/
# Add our generated YANG files
RUN git clone https://github.com/clicon/mib-yangs.git /usr/local/share/mib-yangs
# #
# Stage 2 # Stage 2
# The second step skips the development environment and builds a runtime system # The second step skips the development environment and builds a runtime system
@ -153,6 +156,7 @@ COPY --from=0 /clixon/build/ /usr/local/
COPY --from=0 /usr/local/share/yang/* /usr/local/share/yang/standard/ COPY --from=0 /usr/local/share/yang/* /usr/local/share/yang/standard/
COPY --from=0 /usr/local/share/yang/* /usr/local/share/yang/experimental/ COPY --from=0 /usr/local/share/yang/* /usr/local/share/yang/experimental/
COPY --from=0 /usr/local/share/openconfig/* /usr/local/share/openconfig/ COPY --from=0 /usr/local/share/openconfig/* /usr/local/share/openconfig/
COPY --from=0 /usr/local/share/mib-yangs/* /usr/local/share/mib-yangs/
# Start the backend and restconf deamons # Start the backend and restconf deamons
CMD /usr/local/bin/startsystem.sh CMD /usr/local/bin/startsystem.sh