fedora-40: enable fuse-overfs for buildah

This commit is contained in:
thislight 2024-07-13 21:13:51 +08:00
parent ca39ddc19e
commit 8fab2c4354
No known key found for this signature in database
GPG key ID: A50F9451AC56A63E

View file

@ -4,6 +4,7 @@ RUN dnf update -y --setopt install_weak_deps=False && \
dnf install -y --setopt install_weak_deps=False \
git git-lfs git-ftp \
jq yq sqlite sqlite-devel coreutils brotli zstd binutils aria2 bash \
fuse-overlayfs \
bison flex \
nodejs nodejs-devel nodejs-npm \
julia \
@ -17,7 +18,16 @@ RUN dnf update -y --setopt install_weak_deps=False && \
java-21-openjdk java-21-openjdk-devel \
&& \
dnf group install -y --setopt install_weak_deps=False "C Development Tools and Libraries" && \
dnf group install -y --setopt install_weak_deps=False "Container Management" &&\
dnf group install -y --setopt install_weak_deps=False "Container Management" --exclude container-selinux &&\
dnf clean all -y
# Adjust storage.conf to enable Fuse storage.
RUN sed -i -e 's|^#mount_program|mount_program|g' -e '/additionalimage.*/a "/var/lib/shared",' /etc/containers/storage.conf
RUN mkdir -p /var/lib/shared/overlay-images /var/lib/shared/overlay-layers; touch /var/lib/shared/overlay-images/images.lock; touch /var/lib/shared/overlay-layers/layers.lock
# Set up environment variables to note that this is
# not starting with usernamespace and default to
# isolate the filesystem with chroot.
ENV _BUILDAH_STARTED_IN_USERNS="" BUILDAH_ISOLATION=chroot
ENTRYPOINT [ "/bin/bash" ]