-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathContainerfile.fedora
More file actions
31 lines (24 loc) · 1.13 KB
/
Containerfile.fedora
File metadata and controls
31 lines (24 loc) · 1.13 KB
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
FROM registry.fedoraproject.org/fedora:43
LABEL maintainer="Michael Adam <obnox@samba.org>"
ARG BUILD_LANG=""
ARG INSTALL_SCRIPT=""
ARG VERIFY_SCRIPT=""
LABEL org.opencontainers.image.title="${BUILD_LANG} Build Container"
LABEL org.opencontainers.image.description="Fedora Container for building ${BUILD_LANG} projects"
LABEL org.opencontainers.image.vendor="buildbox"
LABEL org.opencontainers.image.url="https://github.com/TheBuildBox/buildbox"
COPY "${VERIFY_SCRIPT}" /usr/local/bin/verify.sh
COPY common.sh /usr/local/bin/common.sh
RUN chmod +x /usr/local/bin/verify.sh
COPY "${INSTALL_SCRIPT}" /usr/local/bin/install-packages.sh
RUN chmod +x /usr/local/bin/install-packages.sh
# force a sane PATH for the duration of the install
ENV PATH=/usr/local/bin:/usr/bin:/bin:/sbib:/usr/local/sbin:/usr/sbin
# install, fix, and verify in ONE ATOMIC STEP
RUN true && \
/usr/local/bin/install-packages.sh && \
echo "Restoring symlinks if broken..." && \
( [ -L /bin ] || (mv /bin/* /usr/bin/ && rm -rf /bin && ln -s usr/bin /bin) ) && \
echo "Verifying binaries before layer commit..." && \
/usr/local/bin/verify.sh && \
echo "your buildbox is ready."