| 1 |
FROM registry.fedoraproject.org/fedora:36 |
| 2 |
|
| 3 |
ENV NAME=fedora-toolbox VERSION=36 |
| 4 |
LABEL com.github.containers.toolbox="true" \ |
| 5 |
com.redhat.component="$NAME" \ |
| 6 |
name="$NAME" \ |
| 7 |
version="$VERSION" \ |
| 8 |
usage="This image is meant to be used with the toolbox command" \ |
| 9 |
summary="Base image for creating Fedora toolbox containers" \ |
| 10 |
maintainer="Debarshi Ray <[email protected]>" |
| 11 |
|
| 12 |
COPY README.md / |
| 13 |
|
| 14 |
RUN rm /etc/rpm/macros.image-language-conf |
| 15 |
RUN sed -i '/tsflags=nodocs/d' /etc/dnf/dnf.conf |
| 16 |
|
| 17 |
RUN dnf -y upgrade |
| 18 |
RUN dnf -y swap coreutils-single coreutils-full |
| 19 |
RUN dnf -y swap glibc-minimal-langpack glibc-all-langpacks |
| 20 |
|
| 21 |
COPY missing-docs / |
| 22 |
RUN dnf -y reinstall $(<missing-docs) |
| 23 |
RUN rm /missing-docs |
| 24 |
|
| 25 |
COPY extra-packages / |
| 26 |
RUN dnf -y install $(<extra-packages) |
| 27 |
RUN rm /extra-packages |
| 28 |
|
| 29 |
COPY ensure-files / |
| 30 |
RUN ret_val=0; \ |
| 31 |
while read file; do \ |
| 32 |
if ! compgen -G "$file" >/dev/null; then \ |
| 33 |
echo "$file: No such file or directory" >&2; \ |
| 34 |
ret_val=1; \ |
| 35 |
break; \ |
| 36 |
fi; \ |
| 37 |
done <ensure-files; \ |
| 38 |
if [ "$ret_val" -ne 0 ]; then \ |
| 39 |
false; \ |
| 40 |
fi |
| 41 |
RUN rm /ensure-files |
| 42 |
|
| 43 |
RUN dnf clean all |