summaryrefslogtreecommitdiff
path: root/docker
diff options
context:
space:
mode:
authorsarthurdev <965089+sarthurdev@users.noreply.github.com>2023-02-23 00:50:00 +0100
committersarthurdev <965089+sarthurdev@users.noreply.github.com>2023-02-23 01:20:16 +0100
commit7b1b408888fe5ddb3e815e606eec15809f50e38f (patch)
tree535515e6f840a1d4ace3c8e87cd056e7ab755245 /docker
parent5aae6a44a758bbc8f413a190bd019b728f6e67be (diff)
downloadvyos-build-7b1b408888fe5ddb3e815e606eec15809f50e38f.tar.gz
vyos-build-7b1b408888fe5ddb3e815e606eec15809f50e38f.zip
docker: T5003: Use Debian package for yq, fix pip installs, fix open-vmdk build
* Add zlib1g-dev package for open-vmdk build Debian have updated python3-pip to prevent system-wide installs (PEP 668) * Adds and uses `pipx` that will install dependencies within a venv where appropriate * Use `--break-system-packages` argument for j2lint
Diffstat (limited to 'docker')
-rw-r--r--docker/Dockerfile17
1 files changed, 9 insertions, 8 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
index c9f0566b..69b7c20a 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -85,16 +85,15 @@ RUN apt-get update && apt-get install -y \
squashfs-tools \
genisoimage \
fakechroot \
+ pipx \
python3-git \
python3-pip \
python3-flake8 \
python3-autopep8 \
+ yq \
debootstrap \
live-build
-# vyos-build now also makes use of TOML - install yq which has toml support
-RUN pip install yq==3.1.0
-
# Syslinux and Grub2 is only supported on x86 and x64 systems
RUN if dpkg-architecture -ii386 || dpkg-architecture -iamd64; then \
apt-get update && apt-get install -y \
@@ -156,6 +155,10 @@ RUN eval $(opam env --root=/opt/opam --set-root) && \
dpkg-buildpackage -uc -us -tc -b && \
dpkg -i /tmp/libvyosconfig0_*_$(dpkg-architecture -qDEB_HOST_ARCH).deb
+# Packages needed for open-vmdk
+RUN apt-get update && apt-get install -y \
+ zlib1g-dev
+
# Install open-vmdk
RUN wget -O /tmp/open-vmdk-master.zip https://github.com/vmware/open-vmdk/archive/master.zip && \
unzip -d /tmp/ /tmp/open-vmdk-master.zip && \
@@ -242,19 +245,17 @@ RUN export RTRLIB_VERSION="0.8.0" export ARCH=$(dpkg-architecture -qDEB_HOST_ARC
dpkg -i ../librtr0*_${ARCH}.deb ../librtr-dev*_${ARCH}.deb ../rtr-tools*_${ARCH}.deb
# Packages needed to build libyang2
-RUN pip install apkg
RUN apt-get update && apt-get install -y \
graphviz \
cmake \
- libpcre3-dev \
- python3-pip
+ libpcre3-dev
# Prerequisites for building FRR from source
# see http://docs.frrouting.org/projects/dev-guide/en/latest/building-frr-for-debian8.html
#
RUN export LIBYANG_COMMIT="v2.0.164" && \
git clone https://github.com/CESNET/libyang.git && \
- cd libyang && git checkout $LIBYANG_COMMIT && apkg build -i && \
+ cd libyang && git checkout $LIBYANG_COMMIT && pipx run apkg build -i && \
cd pkg/pkgs/debian-*/libyang2_* && dpkg -i *.deb
# Packages needed to build FRR itself
@@ -293,7 +294,7 @@ RUN apt-get update && apt-get install -y \
gprbuild
# Packages needed for vyos-1x
-RUN pip install git+https://github.com/aristanetworks/j2lint.git@341b5d5db86
+RUN pip install --break-system-packages git+https://github.com/aristanetworks/j2lint.git@341b5d5db86
RUN apt-get update && apt-get install -y \
dh-python \
fakeroot \