Usage Building instructions do not work
I'm following the instructions in the Usage / Sample / Manually building Docker images on your local machine
section of README.org
and have hit two issues:
- “Download NSO for evaluation (Linux)” is no longer an item in the side-bar, looks like the link was relocated to “Get NSO for evaluation (Linux)” under “Resources” in the side-bar
- But maybe you could link to this page instead (if the provided image even works with NID, see below)?
- The NSO image available from that page,
nso-5.3.linux.x86_64.signed.bin
(MD539ccdf7c64f2827f9d4c5b0180b26b7c
) does not actually work with themake
target- I have verified that the process works fine with a regular NSO image, i.e.
nso-5.3.2.linux.x86_64.installer.bin
- I have verified that the process works fine with a regular NSO image, i.e.
Console output
klambrec@carbon:~/nso-docker$ make
The default make target will build Docker images out of all the NSO
versions found in nso-install-files/. To also run the test
suite for the built images, run 'make test-all'
make build-all
make[1]: Entering directory '/home/klambrec/nso-docker'
make FILE=/home/klambrec/nso-docker/nso-install-files/nso-5.3.2.linux.x86_64.installer.bin build-file
make[2]: Entering directory '/home/klambrec/nso-docker'
make -C development DOCKER_TAG=5.3.2-klambrec build
make[3]: Entering directory '/home/klambrec/nso-docker/development'
Building NSO development Docker image cisco-nso-dev:5.3.2 based on /home/klambrec/nso-docker/nso-install-files/nso-5.3.2.linux.x86_64.installer.bin
rm -f *.bin
cp /home/klambrec/nso-docker/nso-install-files/nso-5.3.2.linux.x86_64.installer.bin nso-5.3.2.linux.x86_64.installer.bin
docker build --build-arg NSO_INSTALL_FILE=nso-5.3.2.linux.x86_64.installer.bin -t cisco-nso-dev:5.3.2-klambrec .
Sending build context to Docker daemon 187MB
Step 1/15 : FROM debian:buster
---> 1b686a95ddbf
Step 2/15 : ARG NSO_INSTALL_FILE
---> Using cache
---> 54d7431a7702
Step 3/15 : COPY $NSO_INSTALL_FILE /tmp/nso
---> Using cache
---> adf0fd90b793
Step 4/15 : RUN apt-get update && apt-get install -qy openssh-client libexpat1 && sh /tmp/nso --system-install --non-interactive --run-dir /nso/run --log-dir /log && sed -i -e 's/exec python -u/exec python3 -u/' /opt/ncs/current/bin/ncs-start-python-vm
---> Using cache
---> a1800be99ee4
Step 5/15 : FROM debian:buster
---> 1b686a95ddbf
Step 6/15 : RUN apt-get update && apt-get install -qy default-jre-headless iputils-ping libexpat1 openssh-client procps python3 tcpdump telnet xmlstarlet && apt-get -qy autoremove && apt-get clean && rm -rf /var/lib/apt/lists/* /root/.cache && echo '. /opt/ncs/current/ncsrc' >> /root/.bashrc && groupadd ncsadmin && usermod -a -G ncsadmin root
---> Using cache
---> 0eff6b59387b
Step 7/15 : COPY --from=0 /etc/profile.d /etc/profile.d
---> Using cache
---> fd160fb0449d
Step 8/15 : COPY --from=0 /etc/init.d/ncs /etc/init.d/.
---> Using cache
---> 7a54c4f20b8d
Step 9/15 : COPY --from=0 /etc/ncs /etc/ncs/
---> Using cache
---> a553fd1195c2
Step 10/15 : COPY --from=0 /opt/ncs /opt/ncs/
---> Using cache
---> 1a2d5b33ea77
Step 11/15 : COPY --from=0 /nso /nso
---> Using cache
---> a2577401d41a
Step 12/15 : RUN apt-get update && apt-get install -qy ant git iputils-tracepath less liblog4cplus-1.1-9 libuv1 libxml2-utils logrotate make man mypy openssl pylint3 rsync snmp vim-tiny xsltproc && update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.7 3 && update-alternatives --install /usr/bin/python python /usr/bin/python3.7 3 && update-alternatives --install /usr/bin/pylint pylint /usr/bin/pylint3 1 && apt-get -qy autoremove && apt-get clean && rm -rf /var/lib/apt/lists/* /root/.cache
---> Using cache
---> 63a5ce0ba89a
Step 13/15 : SHELL ["/bin/sh", "-lc"]
---> Using cache
---> 5d37553fec80
Step 14/15 : COPY /entrypoint.sh /entrypoint.sh
---> Using cache
---> 2029010adb89
Step 15/15 : ENTRYPOINT ["/entrypoint.sh"]
---> Using cache
---> 8f56ac4cc303
Successfully built 8f56ac4cc303
Successfully tagged cisco-nso-dev:5.3.2-klambrec
rm -f *.bin
make[3]: Leaving directory '/home/klambrec/nso-docker/development'
make -C production-base DOCKER_TAG=5.3.2-klambrec build
make[3]: Entering directory '/home/klambrec/nso-docker/production-base'
Building NSO production Docker image cisco-nso-base:5.3.2 based on /home/klambrec/nso-docker/nso-install-files/nso-5.3.2.linux.x86_64.installer.bin
rm -f *.bin
cp /home/klambrec/nso-docker/nso-install-files/nso-5.3.2.linux.x86_64.installer.bin nso-5.3.2.linux.x86_64.installer.bin
docker build --build-arg NSO_INSTALL_FILE=nso-5.3.2.linux.x86_64.installer.bin -t cisco-nso-base:5.3.2-klambrec .
Sending build context to Docker daemon 187MB
Step 1/17 : FROM debian:buster
---> 1b686a95ddbf
Step 2/17 : ARG NSO_INSTALL_FILE
---> Using cache
---> 54d7431a7702
Step 3/17 : COPY $NSO_INSTALL_FILE /tmp/nso
---> Using cache
---> adf0fd90b793
Step 4/17 : RUN apt-get update && apt-get install -qy openssh-client libexpat1 && sh /tmp/nso --system-install --non-interactive --run-dir /nso/run --log-dir /log && sed -i -e 's/exec python -u/exec python3 -u/' /opt/ncs/current/bin/ncs-start-python-vm
---> Using cache
---> cbe593789087
Step 5/17 : RUN rm -f /etc/ncs/ssh/* && mkdir -p /nid/cdb-default && mv /nso/run/cdb/aaa_init.xml /nid/cdb-default/ && rm -rf /opt/ncs/current/doc /opt/ncs/current/erlang /opt/ncs/current/examples.ncs /opt/ncs/current/include /opt/ncs/current/lib/ncs-project /opt/ncs/current/lib/ncs/lib/confdc /opt/ncs/current/lib/pyang /opt/ncs/current/man /opt/ncs/current/netsim/confd/erlang/econfd/doc /opt/ncs/current/netsim/confd/src/confd/pyapi/doc /opt/ncs/current/packages /opt/ncs/current/src/aaa /opt/ncs/current/src/build /opt/ncs/current/src/cli /opt/ncs/current/src/configuration_policy /opt/ncs/current/src/errors /opt/ncs/current/src/ncs/pyapi/doc /opt/ncs/current/src/ncs_config /opt/ncs/current/src/netconf /opt/ncs/current/src/package-skeletons /opt/ncs/current/src/project-skeletons /opt/ncs/current/src/snmp /opt/ncs/current/src/tools /opt/ncs/current/src/yang /opt/ncs/current/support && sed -i -e 's,<dir>${NCS_RUN_DIR}/packages</dir>,<dir>/var/opt/ncs/packages</dir>,' /etc/ncs/ncs.conf
---> Using cache
---> 901107c5559c
Step 6/17 : FROM debian:buster
---> 1b686a95ddbf
Step 7/17 : RUN apt-get update && apt-get install -qy default-jre-headless iputils-ping libexpat1 openssh-client procps python3 tcpdump telnet xmlstarlet && apt-get -qy autoremove && apt-get clean && rm -rf /var/lib/apt/lists/* /root/.cache && echo '. /opt/ncs/current/ncsrc' >> /root/.bashrc && groupadd ncsadmin && usermod -a -G ncsadmin root
---> Using cache
---> 0eff6b59387b
Step 8/17 : COPY --from=0 /etc/profile.d /etc/profile.d
---> Using cache
---> fd160fb0449d
Step 9/17 : COPY --from=0 /etc/init.d/ncs /etc/init.d/.
---> Using cache
---> 7a54c4f20b8d
Step 10/17 : COPY --from=0 /etc/ncs /etc/ncs/
---> Using cache
---> b52fc3968d71
Step 11/17 : COPY --from=0 /opt/ncs /opt/ncs/
---> Using cache
---> 3758998eb49a
Step 12/17 : COPY --from=0 /nso /nso
---> Using cache
---> a28d53dd0d7b
Step 13/17 : COPY --from=0 /nid /nid
---> Using cache
---> c78738018631
Step 14/17 : COPY extra-files/ /
---> Using cache
---> 9a6a7a493c23
Step 15/17 : EXPOSE 22 80 443 830 4334
---> Using cache
---> 5d550b03e5b9
Step 16/17 : HEALTHCHECK --start-period=60s --interval=5s --retries=3 --timeout=5s CMD /opt/ncs/current/bin/ncs_cmd -c get_phase
---> Using cache
---> 04bbb30e3b17
Step 17/17 : CMD ["/run-nso.sh"]
---> Using cache
---> c3082533e499
Successfully built c3082533e499
Successfully tagged cisco-nso-base:5.3.2-klambrec
rm -f *.bin
make[3]: Leaving directory '/home/klambrec/nso-docker/production-base'
make[2]: Leaving directory '/home/klambrec/nso-docker'
make FILE=/home/klambrec/nso-docker/nso-install-files/nso-5.3.linux.x86_64.signed.bin build-file
make[2]: Entering directory '/home/klambrec/nso-docker'
make -C development DOCKER_TAG=nso-5.3.linux.x86_64.signed.bin-klambrec build
make[3]: Entering directory '/home/klambrec/nso-docker/development'
Building NSO development Docker image cisco-nso-dev:nso-5.3.linux.x86_64.signed.bin based on /home/klambrec/nso-docker/nso-install-files/nso-5.3.linux.x86_64.signed.bin
rm -f *.bin
cp /home/klambrec/nso-docker/nso-install-files/nso-5.3.linux.x86_64.signed.bin nso-5.3.linux.x86_64.signed.bin
docker build --build-arg NSO_INSTALL_FILE=nso-5.3.linux.x86_64.signed.bin -t cisco-nso-dev:nso-5.3.linux.x86_64.signed.bin-klambrec .
Sending build context to Docker daemon 208.2MB
Step 1/15 : FROM debian:buster
---> 1b686a95ddbf
Step 2/15 : ARG NSO_INSTALL_FILE
---> Using cache
---> 54d7431a7702
Step 3/15 : COPY $NSO_INSTALL_FILE /tmp/nso
---> Using cache
---> 833ee82d7803
Step 4/15 : RUN apt-get update && apt-get install -qy openssh-client libexpat1 && sh /tmp/nso --system-install --non-interactive --run-dir /nso/run --log-dir /log && sed -i -e 's/exec python -u/exec python3 -u/' /opt/ncs/current/bin/ncs-start-python-vm
---> Running in 5c7933f35387
Get:1 http://security.debian.org/debian-security buster/updates InRelease [65.4 kB]
Get:2 http://deb.debian.org/debian buster InRelease [121 kB]
Get:3 http://deb.debian.org/debian buster-updates InRelease [51.9 kB]
Get:4 http://security.debian.org/debian-security buster/updates/main amd64 Packages [208 kB]
Get:5 http://deb.debian.org/debian buster/main amd64 Packages [7905 kB]
Get:6 http://deb.debian.org/debian buster-updates/main amd64 Packages [7868 B]
Fetched 8360 kB in 3s (3342 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
krb5-locales libbsd0 libedit2 libgssapi-krb5-2 libk5crypto3 libkeyutils1
libkrb5-3 libkrb5support0 libssl1.1 libx11-6 libx11-data libxau6 libxcb1
libxdmcp6 libxext6 libxmuu1 xauth
Suggested packages:
krb5-doc krb5-user keychain libpam-ssh monkeysphere ssh-askpass
The following NEW packages will be installed:
krb5-locales libbsd0 libedit2 libexpat1 libgssapi-krb5-2 libk5crypto3
libkeyutils1 libkrb5-3 libkrb5support0 libssl1.1 libx11-6 libx11-data
libxau6 libxcb1 libxdmcp6 libxext6 libxmuu1 openssh-client xauth
0 upgraded, 19 newly installed, 0 to remove and 0 not upgraded.
Need to get 4797 kB of archives.
After this operation, 15.2 MB of additional disk space will be used.
Get:1 http://deb.debian.org/debian buster/main amd64 krb5-locales all 1.17-3 [95.4 kB]
Get:2 http://deb.debian.org/debian buster/main amd64 libbsd0 amd64 0.9.1-2 [99.5 kB]
Get:3 http://deb.debian.org/debian buster/main amd64 libedit2 amd64 3.1-20181209-1 [94.0 kB]
Get:4 http://deb.debian.org/debian buster/main amd64 libkeyutils1 amd64 1.6-6 [15.0 kB]
Get:5 http://deb.debian.org/debian buster/main amd64 libkrb5support0 amd64 1.17-3 [65.6 kB]
Get:6 http://deb.debian.org/debian buster/main amd64 libk5crypto3 amd64 1.17-3 [121 kB]
Get:7 http://deb.debian.org/debian buster/main amd64 libssl1.1 amd64 1.1.1d-0+deb10u3 [1538 kB]
Get:8 http://deb.debian.org/debian buster/main amd64 libkrb5-3 amd64 1.17-3 [370 kB]
Get:9 http://deb.debian.org/debian buster/main amd64 libgssapi-krb5-2 amd64 1.17-3 [158 kB]
Get:10 http://deb.debian.org/debian buster/main amd64 openssh-client amd64 1:7.9p1-10+deb10u2 [782 kB]
Get:11 http://deb.debian.org/debian buster/main amd64 libexpat1 amd64 2.2.6-2+deb10u1 [106 kB]
Get:12 http://deb.debian.org/debian buster/main amd64 libxau6 amd64 1:1.0.8-1+b2 [19.9 kB]
Get:13 http://deb.debian.org/debian buster/main amd64 libxdmcp6 amd64 1:1.1.2-3 [26.3 kB]
Get:14 http://deb.debian.org/debian buster/main amd64 libxcb1 amd64 1.13.1-2 [137 kB]
Get:15 http://deb.debian.org/debian buster/main amd64 libx11-data all 2:1.6.7-1 [298 kB]
Get:16 http://deb.debian.org/debian buster/main amd64 libx11-6 amd64 2:1.6.7-1 [754 kB]
Get:17 http://deb.debian.org/debian buster/main amd64 libxext6 amd64 2:1.3.3-1+b2 [52.5 kB]
Get:18 http://deb.debian.org/debian buster/main amd64 libxmuu1 amd64 2:1.1.2-2+b3 [23.9 kB]
Get:19 http://deb.debian.org/debian buster/main amd64 xauth amd64 1:1.0.10-1 [40.3 kB]
debconf: delaying package configuration, since apt-utils is not installed
Fetched 4797 kB in 1s (7275 kB/s)
Selecting previously unselected package krb5-locales.
(Reading database ... 6677 files and directories currently installed.)
Preparing to unpack .../00-krb5-locales_1.17-3_all.deb ...
Unpacking krb5-locales (1.17-3) ...
Selecting previously unselected package libbsd0:amd64.
Preparing to unpack .../01-libbsd0_0.9.1-2_amd64.deb ...
Unpacking libbsd0:amd64 (0.9.1-2) ...
Selecting previously unselected package libedit2:amd64.
Preparing to unpack .../02-libedit2_3.1-20181209-1_amd64.deb ...
Unpacking libedit2:amd64 (3.1-20181209-1) ...
Selecting previously unselected package libkeyutils1:amd64.
Preparing to unpack .../03-libkeyutils1_1.6-6_amd64.deb ...
Unpacking libkeyutils1:amd64 (1.6-6) ...
Selecting previously unselected package libkrb5support0:amd64.
Preparing to unpack .../04-libkrb5support0_1.17-3_amd64.deb ...
Unpacking libkrb5support0:amd64 (1.17-3) ...
Selecting previously unselected package libk5crypto3:amd64.
Preparing to unpack .../05-libk5crypto3_1.17-3_amd64.deb ...
Unpacking libk5crypto3:amd64 (1.17-3) ...
Selecting previously unselected package libssl1.1:amd64.
Preparing to unpack .../06-libssl1.1_1.1.1d-0+deb10u3_amd64.deb ...
Unpacking libssl1.1:amd64 (1.1.1d-0+deb10u3) ...
Selecting previously unselected package libkrb5-3:amd64.
Preparing to unpack .../07-libkrb5-3_1.17-3_amd64.deb ...
Unpacking libkrb5-3:amd64 (1.17-3) ...
Selecting previously unselected package libgssapi-krb5-2:amd64.
Preparing to unpack .../08-libgssapi-krb5-2_1.17-3_amd64.deb ...
Unpacking libgssapi-krb5-2:amd64 (1.17-3) ...
Selecting previously unselected package openssh-client.
Preparing to unpack .../09-openssh-client_1%3a7.9p1-10+deb10u2_amd64.deb ...
Unpacking openssh-client (1:7.9p1-10+deb10u2) ...
Selecting previously unselected package libexpat1:amd64.
Preparing to unpack .../10-libexpat1_2.2.6-2+deb10u1_amd64.deb ...
Unpacking libexpat1:amd64 (2.2.6-2+deb10u1) ...
Selecting previously unselected package libxau6:amd64.
Preparing to unpack .../11-libxau6_1%3a1.0.8-1+b2_amd64.deb ...
Unpacking libxau6:amd64 (1:1.0.8-1+b2) ...
Selecting previously unselected package libxdmcp6:amd64.
Preparing to unpack .../12-libxdmcp6_1%3a1.1.2-3_amd64.deb ...
Unpacking libxdmcp6:amd64 (1:1.1.2-3) ...
Selecting previously unselected package libxcb1:amd64.
Preparing to unpack .../13-libxcb1_1.13.1-2_amd64.deb ...
Unpacking libxcb1:amd64 (1.13.1-2) ...
Selecting previously unselected package libx11-data.
Preparing to unpack .../14-libx11-data_2%3a1.6.7-1_all.deb ...
Unpacking libx11-data (2:1.6.7-1) ...
Selecting previously unselected package libx11-6:amd64.
Preparing to unpack .../15-libx11-6_2%3a1.6.7-1_amd64.deb ...
Unpacking libx11-6:amd64 (2:1.6.7-1) ...
Selecting previously unselected package libxext6:amd64.
Preparing to unpack .../16-libxext6_2%3a1.3.3-1+b2_amd64.deb ...
Unpacking libxext6:amd64 (2:1.3.3-1+b2) ...
Selecting previously unselected package libxmuu1:amd64.
Preparing to unpack .../17-libxmuu1_2%3a1.1.2-2+b3_amd64.deb ...
Unpacking libxmuu1:amd64 (2:1.1.2-2+b3) ...
Selecting previously unselected package xauth.
Preparing to unpack .../18-xauth_1%3a1.0.10-1_amd64.deb ...
Unpacking xauth (1:1.0.10-1) ...
Setting up libexpat1:amd64 (2.2.6-2+deb10u1) ...
Setting up libxau6:amd64 (1:1.0.8-1+b2) ...
Setting up libkeyutils1:amd64 (1.6-6) ...
Setting up libssl1.1:amd64 (1.1.1d-0+deb10u3) ...
debconf: unable to initialize frontend: Dialog
debconf: (TERM is not set, so the dialog frontend is not usable.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.28.1 /usr/local/share/perl/5.28.1 /usr/lib/x86_64-linux-gnu/perl5/5.28 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.28 /usr/share/perl/5.28 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Setting up krb5-locales (1.17-3) ...
Setting up libkrb5support0:amd64 (1.17-3) ...
Setting up libx11-data (2:1.6.7-1) ...
Setting up libk5crypto3:amd64 (1.17-3) ...
Setting up libkrb5-3:amd64 (1.17-3) ...
Setting up libbsd0:amd64 (0.9.1-2) ...
Setting up libxdmcp6:amd64 (1:1.1.2-3) ...
Setting up libxcb1:amd64 (1.13.1-2) ...
Setting up libedit2:amd64 (3.1-20181209-1) ...
Setting up libgssapi-krb5-2:amd64 (1.17-3) ...
Setting up libx11-6:amd64 (2:1.6.7-1) ...
Setting up libxmuu1:amd64 (2:1.1.2-2+b3) ...
Setting up openssh-client (1:7.9p1-10+deb10u2) ...
Setting up libxext6:amd64 (2:1.3.3-1+b2) ...
Setting up xauth (1:1.0.10-1) ...
Processing triggers for libc-bin (2.28-10) ...
ERROR ** Options not understood, --system-install --non-interactive --run-dir /nso/run --log-dir /log
Usage: /tmp/nso [--skip-verification]
This script unpacks the signed release package. It will
save the release image and additional files needed for
signature verification in the current directory, and perform
the signature verification for the image. If signature
verification cannot be performed, e.g. due to lack of
Internet connectivity, the --skip-verification option can be
used to do only the unpack step.
See the installation guide for further information.
The command '/bin/sh -c apt-get update && apt-get install -qy openssh-client libexpat1 && sh /tmp/nso --system-install --non-interactive --run-dir /nso/run --log-dir /log && sed -i -e 's/exec python -u/exec python3 -u/' /opt/ncs/current/bin/ncs-start-python-vm' returned a non-zero code: 9
Makefile:7: recipe for target 'build' failed
make[3]: *** [build] Error 9
make[3]: Leaving directory '/home/klambrec/nso-docker/development'
Makefile:81: recipe for target 'build-file' failed
make[2]: *** [build-file] Error 2
make[2]: Leaving directory '/home/klambrec/nso-docker'
Makefile:99: recipe for target 'build/nso-install-files/nso-5.3.linux.x86_64.signed.bin' failed
make[1]: *** [build/nso-install-files/nso-5.3.linux.x86_64.signed.bin] Error 2
make[1]: Leaving directory '/home/klambrec/nso-docker'
Makefile:42: recipe for target 'all' failed
make: *** [all] Error 2