# SCI Kickstart file for CentOS 7 on jiri.cs.pitt.edu

#version=RHEL7
install
url --url=http://mirror.cs.pitt.edu/centos/7/os/x86_64
lang en_US.UTF-8
keyboard us
network --bootproto static --ip=136.142.227.23 --netmask=255.255.255.128 --gateway=136.142.227.1 --nameserver=136.142.57.10,136.142.188.73,136.142.188.76
rootpw  --iscrypted $6$7sdFE9Ue/kviudcW$Kk6WJ/sq8CBYJCUO/eVCwFDVB.Jfw00Huy3hAzW2byfdh9U32jrTgMvFVXFJaYSt9fFhctdII2ak33s6WOFva/
firewall --service=ssh
authconfig --enableshadow --passalgo=sha512 --enablenis --nisdomain=cs --nisserver=lisa.cs.pitt.edu --enablekrb5 --krb5realm=UNIV.PITT.EDU --krb5kdc=univ.pitt.edu --krb5adminserver=pitt-proddc-01.cssd.pitt.edu
selinux --disabled
timezone America/New_York --isUtc
bootloader --location=mbr --append="crashkernel=auto rhgb quiet"
# The following is the partition information you requested
# Note that any partitions you deleted are not expressed
# here so unless you clear all partitions first, this is
# not guaranteed to work
clearpart --all --initlabel --drives=sda

autopart --type=lvm

repo --name="CentOS"  --baseurl=http://mirror.cs.pitt.edu/centos/7/os/x86_64/ --cost=100
repo --name="CentOS 7 - x86_64 - Updates" --baseurl=http://mirror.cs.pitt.edu/centos/7/updates/x86_64/
#repo --name="Extra Packages for Enterprise Linux 7 - x86_64" --baseurl=http://mirror.cs.pitt.edu/epel/7/x86_64/

%packages
%pre
DISKS="/dev/sda"
for DISK in ${DISKS}; do
    parted -s ${DISK} print 2>&1 |grep "unrecognised disk label" > /dev/null
    if [ $? -eq 0 ]; then
        parted -s ${DISK} mklabel msdos
    fi
done
%end
%post
( wget -O /tmp/files.tar http://install.cs.pitt.edu/centos7/proto/files.tar
  cd /
  tar xfp /tmp/files.tar
  sh /tmp/install
  chmod 1777 /tmp
  sync
) 1>/root/post_install.log 2>&1
%end


%addon com_redhat_kdump --enable --reserve-mb='auto'

%end
