-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathContainerfile
59 lines (49 loc) · 2.17 KB
/
Containerfile
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
FROM docker.io/ubuntu:20.04 AS base-builder
COPY focal-sources.txt /etc/apt/sources.list
RUN echo "force-unsafe-io" >> "/etc/dpkg/dpkg.cfg" && \
dpkg --add-architecture arm64 && \
apt update && \
DEBIAN_FRONTEND=noninteractive apt install --yes \
build-essential devscripts debhelper equivs wget
FROM base-builder AS libsrtp-builder
ARG LIBSRTP_VERSION="2.3.0"
WORKDIR /root
COPY sha512sums_libsrtp.txt /root/sha512sums.txt
RUN wget "https://github.com/cisco/libsrtp/archive/refs/tags/v${LIBSRTP_VERSION}.tar.gz" \
--output-document "libsrtp_${LIBSRTP_VERSION}.orig.tar.gz" && \
sha512sum --check /root/sha512sums.txt && \
mkdir build && \
tar --strip-components=1 --directory=build \
--extract --file "libsrtp_${LIBSRTP_VERSION}.orig.tar.gz"
COPY libsrtp-debian /root/build/debian
ARG BUILD_ARCH="arm64"
WORKDIR /root/build
RUN DEBIAN_FRONTEND=noninteractive \
mk-build-deps \
--tool 'apt --yes -o Debug::pkgProblemResolver=yes --no-install-recommends' \
--host-arch "${BUILD_ARCH}" debian/control \
--install --remove
RUN dpkg-buildpackage --host-arch "${BUILD_ARCH}" --unsigned-source --unsigned-buildinfo --unsigned-changes
FROM base-builder AS janus-builder
ARG JANUS_VERSION="0.10.10"
WORKDIR /root
COPY sha512sums_janus.txt /root/sha512sums.txt
RUN wget "https://github.com/meetecho/janus-gateway/archive/refs/tags/v${JANUS_VERSION}.tar.gz" \
--output-document "janus_${JANUS_VERSION}.orig.tar.gz" && \
sha512sum --check /root/sha512sums.txt && \
mkdir build && \
tar --strip-components=1 --directory=build \
--extract --file "janus_${JANUS_VERSION}.orig.tar.gz"
COPY --from=libsrtp-builder /root/td-libsrtp-dev*.deb ./
RUN DEBIAN_FRONTEND=noninteractive \
apt install --yes --no-install-recommends \
./*.deb
COPY janus-debian /root/build/debian
ARG BUILD_ARCH
WORKDIR /root/build
RUN DEBIAN_FRONTEND=noninteractive \
mk-build-deps \
--tool 'apt --yes -o Debug::pkgProblemResolver=yes --no-install-recommends' \
--host-arch "${BUILD_ARCH}" debian/control \
--install --remove
RUN dpkg-buildpackage --host-arch "${BUILD_ARCH}" --unsigned-source --unsigned-buildinfo --unsigned-changes