Last active
August 8, 2018 14:18
-
-
Save immanuelpotter/1ffce33268b66f235ca6758abc409ae3 to your computer and use it in GitHub Desktop.
Basic template for kickstart installation of minimal images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Prior to use: crypt passwords and add here | |
| install | |
| # System authorization information | |
| auth --enableshadow --passalgo=sha512 | |
| # Use CDROM installation media | |
| #cdrom | |
| # Use graphical install | |
| #graphical | |
| # Run the Setup Agent on first boot | |
| firstboot --enable | |
| # ignoredisk --only-use=sda | |
| # Keyboard layouts | |
| keyboard --vckeymap=gb --xlayouts='gb' | |
| # System language | |
| lang en_GB.UTF-8 | |
| # Timezone | |
| timezone --utc | |
| # Network information | |
| network --bootproto=dhcp --device=eth0 --activate | |
| network --hostname=hardbox | |
| # Root password - disable in post-install script | |
| rootpw --iscrypted ${ROOT_PW_HASH} | |
| # Grub password | |
| bootloader --password=${GRUB_PW_HASH} --iscrypted | |
| # System services | |
| services --disabled="chronyd" | |
| # System timezone | |
| timezone Europe/London --isUtc --nontp | |
| # User to begin with - change immediately after install | |
| user --groups=wheel --name=${ADMIN_USER} --password="${ADMIN_PW_HASH}" --iscrypted --gecos="Admin User" | |
| # Disable root from ssh during installation | |
| sshpw --username=root --plaintext root --lock | |
| # System bootloader configuration | |
| bootloader --append=" crashkernel=auto" --location=mbr --boot-drive=sda | |
| # Partition clearing information | |
| zerombr | |
| clearpart --all --drives=sda --initlabel | |
| part /boot --fstype="xfs" --ondisk=sda --size=${BOOT_SIZE} | |
| part pv.01 --fstype="lvmpv" --ondisk=sda --size=${PV_SIZE} --grow --encrypted --passphrase=${ENCRYPTION_PASS} | |
| volgroup centos pv.01 | |
| logvol /tmp --fstype="xfs" --size=${TMP_SIZE} --name=tmp --vgname=centos | |
| logvol /var --fstype="xfs" --size=${VAR_SIZE} --name=var --vgname=centos | |
| logvol swap --fstype="swap" --recommended --name=swap --vgname=centos | |
| logvol /var/tmp --fstype="xfs" --size=${VAR_TMP_SIZE} --name=var_tmp --vgname=centos | |
| logvol / --fstype="xfs" --size=${ROOT_SIZE} --name=root --vgname=centos | |
| logvol /var/log --fstype="xfs" --size=${VAR_LOG_SIZE} --name=var_log --vgname=centos | |
| logvol /var/log/audit --fstype="xfs" --size=${VAR_LOG_AUDIT_SIZE} --name=var_log_audit --vgname=centos | |
| logvol /home --fstype="xfs" --size=${HOME_SIZE} --name=home --vgname=centos | |
| selinux --enforcing | |
| reboot | |
| %packages | |
| @^minimal | |
| @core | |
| kexec-tools | |
| %end | |
| %addon com_redhat_kdump --enable --reserve-mb='auto' | |
| %end | |
| %anaconda | |
| pwpolicy root --minlen=14 --minquality=1 --nochanges --notempty | |
| pwpolicy user --minlen=14 --minquality=1 --nochanges --notempty | |
| pwpolicy luks --minlen=14 --minquality=1 --nochanges --notempty | |
| %end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment