This repository was archived by the owner on Jun 12, 2022. It is now read-only.
forked from travelping/upg-vpp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.devel
45 lines (38 loc) · 1.8 KB
/
Dockerfile.devel
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# syntax = docker/dockerfile:experimental
# the following is updated automatically by make update-build-image-tag
FROM quay.io/travelping/upg-build:90cf570f931007523db7085e7d867659 AS build-stage
ADD vpp /src/vpp
ADD upf /src/upf
RUN --mount=target=/src/vpp/build-root/.ccache,type=cache \
make -C /src/vpp pkg-deb-debug V=1 && \
mkdir -p /out/debs && \
mv /src/vpp/build-root/*.deb /out/debs && \
tar -C /src/vpp -cvzf /out/testfiles.tar.gz build-root/install-vpp_debug-native
# pseudo-image to extract artifact using buildctl
FROM scratch as artifacts
COPY --from=build-stage /out .
# --- final image --------------------------------------------
FROM ubuntu:bionic AS final-stage
WORKDIR /
RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=private \
--mount=target=/var/cache/apt,type=cache,sharing=private \
apt-get update && apt-get dist-upgrade -yy && \
apt-get install --no-install-recommends -yy liblz4-tool tar gdb strace \
libhyperscan4 libmbedcrypto1 libmbedtls10 libmbedx509-0 libpython-stdlib \
libpython2.7-minimal libpython2.7-stdlib libpython3-stdlib \
python python-cffi python-cffi-backend python-ipaddress \
python-minimal python-ply python-pycparser python2.7 python2.7-minimal \
python3 python3-minimal python3.6 python3.6-minimal
# TODO: add more packages above that are VPP deps
RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=private \
--mount=target=/var/cache/apt,type=cache,sharing=private \
--mount=target=/debs,source=/out/debs,from=build-stage,type=bind \
apt-get install --no-install-recommends -yy \
/debs/vpp_*.deb \
/debs/vpp-dev_*.deb \
/debs/vpp-dbg_*.deb \
/debs/vpp-plugin-core_*.deb \
/debs/libvppinfra_*.deb \
/debs/libvppinfra-dev_*.deb \
/debs/vpp-api-python_*.deb
ENTRYPOINT /usr/bin/vpp