docker-images/repoman.Dockerfile

43 lines
1.5 KiB
Docker

# Portage tree.
FROM gentoo/portage:latest as portage
# Minimal Gentoo image without build dependencies.
FROM tastytea/gentoo-base:latest as gentoo-base
# Build packages in /workdir.
FROM gentoo/stage3:amd64-nomultilib-openrc as build
COPY --from=portage /var/db/repos/gentoo /var/db/repos/gentoo
COPY --from=gentoo-base / /workdir
RUN cp /workdir/etc/portage/make.conf /etc/portage/make.conf
ENV USE "-curl -idn -net -ssl -webdav"
RUN eselect profile set default/linux/amd64/17.1/no-multilib
RUN mkdir -p /etc/portage/package.accept_keywords
RUN echo 'app-portage/repoman' \
>> /etc/portage/package.accept_keywords/portage
RUN echo '*/* PYTHON_TARGETS: -python2_7' >> /etc/portage/package.use/python
RUN quickpkg --include-config=y @world sys-libs/glibc
RUN emerge --root=/workdir --buildpkg=y --usepkg --quiet \
app-portage/repoman dev-vcs/git
RUN emerge --root=/workdir --rage-clean --quiet \
app-arch/tar \
app-arch/xz-utils \
dev-libs/openssl \
net-dns/libidn2 \
net-misc/rsync \
sys-apps/file \
sys-apps/sed \
dev-lang/perl \
sys-libs/timezone-data \
app-misc/ca-certificates
RUN rm -r /workdir/usr/share/gtk-doc
RUN rm -r /workdir/usr/include
RUN rm -r /workdir/var/db/pkg
# Final image.
FROM gentoo/portage:latest
LABEL maintainer="tastytea+docker@tastytea.de"
LABEL description="Latest ~amd64 app-portage/repoman."
COPY --from=build /workdir /
RUN eselect profile set default/linux/amd64/17.1/no-multilib
ENV LANG "en_DK.utf8"