diff options
author | ebo <eliezio.oliveira@est.tech> | 2020-04-19 01:33:21 +0100 |
---|---|---|
committer | Bartek Grzybowski <b.grzybowski@partner.samsung.com> | 2020-04-20 07:11:26 +0000 |
commit | ee0c74e28de9552e683724264b101362c144694c (patch) | |
tree | 84aef9e38cbdd4c88e25f3bbbe6bff6af703fb20 /test/mocks/netconf-pnp-simulator/engine/Dockerfile | |
parent | 93d2ff22d0c8c1bc1fc7a2ea5e5643c88a345667 (diff) |
netconf-pnp-simulator: fix sysrepod crash on TLS reconfig
The crash was caused by:
- the '--permanent' option while updating the ietf-keystore by
sysrepocfg
- missing some Yang modules on sysrepo installation
Other changes:
1. Added TLS integration tests, including reconfiguration
2. reconfigure-*.sh are now synchronous, only returnig after restart is
completed
Issue-ID: INT-1516
Change-Id: Iddc03fc968aaab60931596045437ba0c78448b08
Signed-off-by: ebo <eliezio.oliveira@est.tech>
Diffstat (limited to 'test/mocks/netconf-pnp-simulator/engine/Dockerfile')
-rw-r--r-- | test/mocks/netconf-pnp-simulator/engine/Dockerfile | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/test/mocks/netconf-pnp-simulator/engine/Dockerfile b/test/mocks/netconf-pnp-simulator/engine/Dockerfile index 9eec0baa7..3afca4b6d 100644 --- a/test/mocks/netconf-pnp-simulator/engine/Dockerfile +++ b/test/mocks/netconf-pnp-simulator/engine/Dockerfile @@ -65,8 +65,7 @@ RUN set -eux \ && mkdir build && cd build \ && cmake -DCMAKE_BUILD_TYPE:String="Release" -DENABLE_BUILD_TESTS=OFF \ -DCMAKE_INSTALL_PREFIX:PATH=/opt \ - -DGEN_LANGUAGE_BINDINGS=ON \ - -DPYTHON_MODULE_PATH:PATH=/opt/lib/python3.7/site-packages \ + -DGEN_LANGUAGE_BINDINGS=OFF \ .. \ && make -j2 \ && make install @@ -98,6 +97,7 @@ RUN set -eux \ -DGEN_PYTHON_VERSION=3 \ -DPYTHON_MODULE_PATH:PATH=/opt/lib/python3.7/site-packages \ -DBUILD_EXAMPLES=0 \ + -DBUILD_CPP_EXAMPLES=0 \ .. \ && make -j2 \ && make install @@ -111,8 +111,7 @@ RUN set -eux \ && mkdir build && cd build \ && cmake -DCMAKE_BUILD_TYPE:String="Release" -DENABLE_BUILD_TESTS=OFF \ -DCMAKE_INSTALL_PREFIX:PATH=/opt \ - -DENABLE_PYTHON=ON \ - -DPYTHON_MODULE_PATH:PATH=/opt/lib/python3.7/site-packages \ + -DENABLE_PYTHON=OFF \ .. \ && make \ && make install @@ -127,6 +126,7 @@ RUN set -eux \ && mkdir build && cd build \ && cmake -DCMAKE_BUILD_TYPE:String="Release" \ -DCMAKE_INSTALL_PREFIX:PATH=/opt \ + -DMODEL_INSTALL=ON \ .. \ && make -j2 \ && make install @@ -141,14 +141,16 @@ RUN set -eux \ && make -j2 \ && make install -FROM python:3.7.7-alpine3.11 +FROM python:3.7.7-alpine3.11 as stage0 +RUN apk upgrade --no-cache --available + +FROM scratch LABEL authors="eliezio.oliveira@est.tech" +COPY --from=stage0 / / + RUN set -eux \ - && pip install loguru supervisor virtualenv \ - && apk update \ - && apk upgrade -a \ - && apk add \ + && apk add --no-cache \ coreutils \ libcurl \ libev \ @@ -156,8 +158,7 @@ RUN set -eux \ openssl \ pcre \ protobuf-c \ - xmlstarlet \ - && rm -rf /var/cache/apk/* + xmlstarlet COPY --from=build /opt/ /opt/ @@ -167,6 +168,7 @@ ENV PYTHONPATH=/opt/lib/python3.7/site-packages COPY patches/supervisor/ /usr/src/patches/supervisor/ RUN set -eux \ + && pip install loguru supervisor supervisor virtualenv \ && cd /usr/local/lib/python3.7/site-packages \ && for p in /usr/src/patches/supervisor/*.patch; do patch -p1 -i $p; done @@ -181,8 +183,12 @@ RUN adduser --system --disabled-password --gecos 'Netconf User' netconf # it can start the tests. HEALTHCHECK --interval=1s --start-period=2s --retries=10 CMD test -f /run/netopeer2-server.pid +# SSH EXPOSE 830 +# TLS +EXPOSE 6513 + COPY supervisord.conf /etc/supervisord.conf RUN mkdir /etc/supervisord.d |