1
0
mirror of https://github.com/AlmaLinux/ks2rootfs.git synced 2024-11-14 23:13:07 +00:00
ks2rootfs/Dockerfile.livecd

32 lines
1.0 KiB
Docker
Raw Normal View History

2021-08-06 03:56:07 +00:00
# ----------------------------------------------------------------------------
# Multi stage docker build for live cd tools in docker/container environment
# AlmaLinux Init + Live CD Tools + PyKickStart
# ----------------------------------------------------------------------------
FROM almalinux:8 as builder
RUN dnf install -y epel-release elrepo-release && \
dnf upgrade -y && \
mkdir -p /mnt/system-root /mnt/system-root/code; \
2021-08-09 03:46:11 +00:00
dnf install --enablerepo="powertools" --enablerepo="epel" --enablerepo="elrepo" --installroot /mnt/system-root --releasever 8 --setopt=install_weak_deps=False --setopt=tsflags=nodocs -y \
dnf \
systemd \
livecd-tools \
pykickstart \
hfsplus-tools \
grub2-efi-x64 \
grub2-efi-x64-cdboot \
shim-x64 ; \
2021-08-06 03:56:07 +00:00
rm -rf /mnt/system-root/var/cache/* ; \
dnf clean all; \
cp /etc/yum.repos.d/* /mnt/system-root/etc/yum.repos.d/ ; \
rm -rf /var/cache/yum;
# Create Final image from scratch for ks2rootfs
FROM scratch
COPY --from=builder /mnt/system-root/ /
WORKDIR /code
2021-08-06 03:56:07 +00:00
CMD ["/bin/bash"]