-
Notifications
You must be signed in to change notification settings - Fork 2
/
ks.tmpl
74 lines (55 loc) · 2.15 KB
/
ks.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# Forces the text install to be used
text
# Tells kickstart to start the install
install
# Skips the display of any GUI during install
skipx
# Specifies the language
lang en_US.UTF-8
# Specifies the keyboard layout
keyboard us
# Used with an HTTP install to specify where the install files are located
url --url http://mirror.centos.org/{{.os}}/{{.version}}/os/x86_64/
# Setup the network interface
network --onboot yes --bootproto dhcp --noipv6 --hostname {{.fqdn}}
# Set the root password
rootpw --iscrypted $1$iu7Ryr.x$xapoDtZ5a3HAHdgrZjN6B/ ## password
# Disable firewall
firewall --disable
# Disabled selinux
selinux --disabled
# Set the timezone
timezone --utc UTC
# Prepare all my drives. You must list drives that it will contain the OS
clearpart --all --initlabel --drives=sda
# Create the bootloader in the MBR with drive sda being the drive to install it on
bootloader --location=mbr --driveorder=sda,sdb,sdc --append="crashkernel=auto rhgb"
# Sets up the authentication options for the system
authconfig --enableshadow --passalgo=sha512
# Create the bootloader in the MBR with drive sda being the drive to install it on
bootloader --location=mbr --driveorder=hda
# Wipe all partitions and build them with the info below
zerombr
clearpart --all --initlabel --drives=sda
part /boot --fstype ext4 --size=1024 --ondisk=sda --asprimary
part pv.100000 --size=100 --grow --ondisk=sda
volgroup vg0 --pesize=32768 pv.100000
logvol / --fstype ext4 --name=root --vgname=vg0 --size=8192
logvol swap --fstype swap --name=swap --vgname=vg0 --size=2048
logvol /tmp --fstype ext4 --name=tmp --vgname=vg0 --size=3072
logvol /var --fstype ext4 --name=var --vgname=vg0 --size=3072
logvol /home --fstype ext4 --name=home --vgname=vg0 --size=2048
reboot
%packages
@core
# List packages which will be installed after the OS finish installing.
%end
%pre
### You can add commands to run on the system immediately after the ks.cfg has been parsed.
%end
%post
### Anything in the %post section is treated as if you were
### typing it at the console of a system. You can perform cus-
### tomizations or execute other scripts for further configuration of
### your system.
%end