-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile.deps
21 lines (16 loc) · 1.17 KB
/
Dockerfile.deps
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
ARG BASE
FROM ${BASE}
CMD rsync --delete -vcr /tmp/binpkg-cache/. /var/cache/binpkgs/.
RUN wget --progress=dot:mega -O - https://github.com/gentoo-mirror/gentoo/archive/master.tar.gz | tar -xz \
&& mv gentoo-master /var/db/repos/gentoo
ARG DOCKER_DEPS
ARG CFLAGS
ARG LDFLAGS
ARG USE
COPY package.accept_keywords /etc/portage/package.accept_keywords/local
COPY package.use /etc/portage/package.use/local
RUN printf '\nCFLAGS="%s"\nCXXFLAGS="%s"\nLDFLAGS="%s"\nBINPKG_COMPRESS="xz"\nBINPKG_COMPRESS_FLAGS="-T1 -9"\nFEATURES="${FEATURES} -sandbox -usersandbox -cgroup binpkg-multi-instance -binpkg-docompress -binpkg-dostrip parallel-install -ipc-sandbox -network-sandbox -pid-sandbox"\nACCEPT_LICENSE="*"\nPKGDIR="/tmp/binpkg"\nBINPKG_FORMAT="gpkg"\nPORTAGE_BINHOST="http://127.0.0.1:8787/"\nMODULES_SIGN_KEY="/tmp/signing_key.pem"\nSECUREBOOT_SIGN_KEY="/tmp/signing_key.pem"\nSECUREBOOT_SIGN_CERT="/tmp/signing_key.pem"\nUSE="%s"\n' "${CFLAGS}" "${CFLAGS}" "${LDFLAGS}" "${USE}" >> /etc/portage/make.conf \
&& rm -rf /etc/portage/binrepos.conf \
&& { [[ -z ${DOCKER_DEPS} ]] || PKGDIR=/tmp/binpkg-cache emerge -1vbgt --jobs ${DOCKER_DEPS}; } \
&& emerge --info \
&& cat /etc/portage/make.conf