Skip to content

Instantly share code, notes, and snippets.

@jgstew
Last active September 21, 2016 04:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jgstew/1d878a68f3fc2b761fb695693519bf26 to your computer and use it in GitHub Desktop.
Save jgstew/1d878a68f3fc2b761fb695693519bf26 to your computer and use it in GitHub Desktop.
rename this file to `ks.cfg` and place within the root of the ISO. Then add `inst.ks=cdrom` to the boot options within `grub.cfg` and `isolinux.cfg`
#version=DEVEL
# Reference: https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/Installation_Guide/sect-kickstart-syntax.html
# System authorization information
auth --enableshadow --passalgo=sha512
# Use CDROM installation media
install
cdrom
# Use text install
text
# Run the Setup Agent on first boot
firstboot --enable
ignoredisk --only-use=sda
# Keyboard layouts
keyboard --vckeymap=us --xlayouts='us'
# System language
lang en_US.UTF-8
# Network information
network --bootproto=dhcp --device=eth0 --ipv6=auto --activate
# https://www.centos.org/forums/viewtopic.php?t=11861
# http://serverfault.com/questions/441497/how-to-get-centos-6-kickstart-to-ask-for-hostname
#network --device=eth0 --bootproto=query
network --hostname=centostestks
#Root password
rootpw --lock
# System services
services --disabled="chronyd"
# System timezone
timezone America/Los_Angeles --isUtc --nontp
# password is password
user --groups=wheel --name=centos --password=$6$CcsLDN2EUviPeIeU$yrM8iKn8BDOvaZZvIJS/4PU4tfRh2/sVVpKU/ZlzX6HcWyZiV1GAteRfuEG869LBEHP4RhuN.qNZLiPaOPG2j. --iscrypted --gecos="centos"
# System bootloader configuration
bootloader --location=mbr --boot-drive=sda
# Partition clearing information
clearpart --none --initlabel
autopart --type=lvm
# agree to EULA
eula --agreed
# Attempt to eject the installation DVD (if installing from a DVD) before rebooting.
reboot --eject
%packages
@^minimal
@core
curl
%end
%addon com_redhat_kdump --disable
%end
# run after setup
%post
curl -o install_bigfix.sh https://raw.githubusercontent.com/jgstew/tools/master/bash/install_bigfix.sh
chmod u+x install_bigfix.sh
./install_bigfix.sh alpha.bigfix.com
%end