From 774fb63ec30feb35fad3c6eb8686e4392ea0c09b Mon Sep 17 00:00:00 2001 From: Fabian Arrotin Date: Aug 01 2019 12:50:18 +0000 Subject: Renamed container image to be generic Signed-off-by: Fabian Arrotin --- diff --git a/CentOS-8-Container.ks b/CentOS-8-Container.ks new file mode 100644 index 0000000..75671a4 --- /dev/null +++ b/CentOS-8-Container.ks @@ -0,0 +1,92 @@ +# This is a minimal CentOS kickstart designed for docker. +# It will not produce a bootable system +# To use this kickstart, run the following command +# livemedia-creator --make-tar \ +# --iso=/path/to/boot.iso \ +# --ks=centos-8.ks \ +# --image-name=centos-root.tar.xz +# + +# Basic setup information +install +keyboard us +rootpw --lock --iscrypted locked +timezone --isUtc --nontp UTC +selinux --enforcing +firewall --disabled +network --bootproto=dhcp --device=link --activate --onboot=on +shutdown +bootloader --disable +lang en_US + + +# Disk setup +zerombr +clearpart --all --initlabel +autopart --noboot --nohome --noswap --nolvm --fstype=ext4 + +# Package setup +%packages --excludedocs --instLangs=en --nocore +centos-release +binutils +-brotli +bash +hostname +rootfiles +coreutils-single +glibc-minimal-langpack +vim-minimal +less +-gettext* +-firewalld +-os-prober* +tar +-iptables +iputils +-kernel +-dosfstools +-e2fsprogs +-fuse-libs +-gnupg2-smime +-libss +-pinentry +-shared-mime-info +-trousers +-xkeyboard-config +-xfsprogs +-qemu-guest-agent +yum +-grub\* + +%end + +%post --erroronfail --log=/root/anaconda-post.log +# container customizations inside the chroot + +echo 'container' > /etc/dnf/vars/infra + +#Generate installtime file record +/bin/date +%Y%m%d_%H%M > /etc/BUILDTIME + +# Limit languages to help reduce size. +LANG="en_US" +echo "%_install_langs $LANG" > /etc/rpm/macros.image-language-conf + + +# systemd fixes +:> /etc/machine-id +umount /run +systemd-tmpfiles --create --boot +# mask mounts and login bits +systemctl mask systemd-logind.service getty.target console-getty.service sys-fs-fuse-connections.mount systemd-remount-fs.service dev-hugepages.mount + +# Remove things we don't need +rm -f /etc/udev/hwdb.bin +rm -rf /usr/lib/udev/hwdb.d/ +rm -rf /boot +rm -rf /var/lib/dnf/history.* + + +%end + + diff --git a/CentOS-8-Docker.ks b/CentOS-8-Docker.ks deleted file mode 100644 index 75671a4..0000000 --- a/CentOS-8-Docker.ks +++ /dev/null @@ -1,92 +0,0 @@ -# This is a minimal CentOS kickstart designed for docker. -# It will not produce a bootable system -# To use this kickstart, run the following command -# livemedia-creator --make-tar \ -# --iso=/path/to/boot.iso \ -# --ks=centos-8.ks \ -# --image-name=centos-root.tar.xz -# - -# Basic setup information -install -keyboard us -rootpw --lock --iscrypted locked -timezone --isUtc --nontp UTC -selinux --enforcing -firewall --disabled -network --bootproto=dhcp --device=link --activate --onboot=on -shutdown -bootloader --disable -lang en_US - - -# Disk setup -zerombr -clearpart --all --initlabel -autopart --noboot --nohome --noswap --nolvm --fstype=ext4 - -# Package setup -%packages --excludedocs --instLangs=en --nocore -centos-release -binutils --brotli -bash -hostname -rootfiles -coreutils-single -glibc-minimal-langpack -vim-minimal -less --gettext* --firewalld --os-prober* -tar --iptables -iputils --kernel --dosfstools --e2fsprogs --fuse-libs --gnupg2-smime --libss --pinentry --shared-mime-info --trousers --xkeyboard-config --xfsprogs --qemu-guest-agent -yum --grub\* - -%end - -%post --erroronfail --log=/root/anaconda-post.log -# container customizations inside the chroot - -echo 'container' > /etc/dnf/vars/infra - -#Generate installtime file record -/bin/date +%Y%m%d_%H%M > /etc/BUILDTIME - -# Limit languages to help reduce size. -LANG="en_US" -echo "%_install_langs $LANG" > /etc/rpm/macros.image-language-conf - - -# systemd fixes -:> /etc/machine-id -umount /run -systemd-tmpfiles --create --boot -# mask mounts and login bits -systemctl mask systemd-logind.service getty.target console-getty.service sys-fs-fuse-connections.mount systemd-remount-fs.service dev-hugepages.mount - -# Remove things we don't need -rm -f /etc/udev/hwdb.bin -rm -rf /usr/lib/udev/hwdb.d/ -rm -rf /boot -rm -rf /var/lib/dnf/history.* - - -%end - -