Created
October 3, 2012 20:23
-
-
Save greghaynes/3829618 to your computer and use it in GitHub Desktop.
This file contains 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
#platform=x86, AMD64, or Intel EM64T | |
# XXX salt context | |
# grains: | |
# cpuarch: i386 or x86_64 | |
# virtual: physical or kvm | |
{% if grains['cpuarch'].endswith('86') %} | |
{% set arch = 'i386' %} | |
{% else %} | |
{% set arch = grains['cpuarch'] %} | |
{% endif %} | |
# http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/6/html/Installation_Guide/s1-kickstart2-options.html | |
# System authorization information | |
auth --useshadow --enablemd5 | |
# System bootloader configuration | |
bootloader --location=mbr | |
# Partition clearing information | |
clearpart --all --initlabel | |
# Use text mode install | |
text | |
# Firewall configuration | |
firewall --disabled | |
# Run the Setup Agent on first boot | |
firstboot --disable | |
# System keyboard | |
keyboard us | |
# System language | |
lang en_US.UTF-8 | |
# Install OS instead of upgrade | |
install | |
# Logging of installer messages | |
logging --host logger.service.awb | |
# Network information | |
network --bootproto=dhcp --device=eth0 | |
# Reboot after installation | |
reboot | |
# repos | |
repo --name=epel --mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-6&arch={{ arch }} | |
repo --name=epel-testing --mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=testing-epel6&arch={{ arch }} | |
# SELinux configuration | |
selinux --disabled | |
# Do not configure the X Window System | |
skipx | |
# System timezone | |
timezone Etc/UTC | |
# Clear the Master Boot Record | |
zerombr | |
{% if grains['virtual'] == 'kvm' %} | |
{% set disk = 'vda' %} | |
{% else %} | |
{% set disk = 'sda' %} | |
{% endif %} | |
part /boot --fstype ext3 --size=150 --ondisk={{ disk }} | |
part pv.01 --size=1 --grow --ondisk={{ disk }} | |
volgroup default pv.01 | |
logvol / --fstype ext4 --name=root --vgname=default --size=5120 | |
logvol swap --fstype swap --name=swap --vgname=default --size=1024 | |
rootpw --iscrypted $6$IkSYo5sY$XMB1aj03.xlkvM0DQpvEeU1TfdxnAVD4/BwShTJLYioZdfB7yy7Eao8Gr6NaUhpqB19bsE25FwNRftqfaVbwM/ | |
user --name=idealist --iscrypted --password=$6$PcgBWrUJ$8GuCVldQ3iP/8XYKcyhgJoIU8p9bcZRO4jVTW3rOb7e9OmlvD/OqxSOWmTgBOcGFQ/XQ5fVVVTUwY7zL7IzSx/ --groups=wheel | |
services --enabled sshd | |
%packages | |
@core | |
#salt-minion | |
#mg | |
#tmux | |
sudo | |
%post | |
sed -i 's/^\#PermitRootLogin yes/PermitRootLogin no/' /etc/ssh/sshd_config | |
echo "%wheel ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers | |
cat > /etc/sysconfig/network-scripts/ifcfg-eth0 <<EOF | |
DEVICE=eth0 | |
ONBOOT=yes | |
BRIDGE=br0 | |
EOF | |
cat > /etc/sysconfig/network-scripts/ifcfg-br0 <<EOF | |
DEVICE=br0 | |
ONBOOT=yes | |
TYPE=Bridge | |
BOOTPROTO=dhcp | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment