From: Frank Brehm Date: Wed, 10 Jun 2020 14:36:00 +0000 (+0200) Subject: Adding kickstart/template-centos8.ks X-Git-Tag: 2.1.2^2~9^2~31^2~65 X-Git-Url: https://git.uhu-banane.org/?a=commitdiff_plain;h=6cb5c75bb61f980ba763ff5c9a47f4fc7dd263f0;p=pixelpark%2Fcreate-vmware-tpl.git Adding kickstart/template-centos8.ks --- diff --git a/kickstart/template-centos8.ks b/kickstart/template-centos8.ks new file mode 100644 index 0000000..3128374 --- /dev/null +++ b/kickstart/template-centos8.ks @@ -0,0 +1,155 @@ +###################################################################################### +# Centos8 for Privisioning-Installation +###################################################################################### +# +# Standard Pixelpark Installation of CentOS 8 templates +# + +# Firewall configuration +firewall --disabled + +# Use network installation +url --url="https://repo01.pixelpark.com/Linux/yum/centos/8/BaseOS/x86_64/os" --noverifyssl + +sshpw --username=inst testtest --plaintext + +# Root install-password +rootpw --iscrypted ${ROOT_PWD_HASH} +# System authorization information +auth --useshadow --passalgo=sha512 +# Use text mode install +text +# System keyboard +keyboard de +# System language +lang en_US +# SELinux configuration +selinux --permissiv +# Do not configure the X Window System +skipx +# Installation logging level +logging --level=debug +# Reboot after installation +reboot +# System timezone +timezone Europe/Berlin + +########################################### +# Partitioning and Disk + +# System bootloader configuration +bootloader --location=mbr --append="net.ifnames=0 biosdevname=0" + +# Partition clearing information +clearpart --all --drive=sda + +# Disk partitioning information +part /boot --fstype ext4 --size=512 --ondisk=sda +part swap --size=${SWAP_SIZE_MB} --ondisk=sda +part pv.01 --size=1 --grow --ondisk=sda +volgroup vgroot pv.01 +logvol /home --vgname=vgroot --name=home --size=4096 +logvol / --vgname=vgroot --name=root --size=10240 +logvol /var --vgname=vgroot --name=var --size=1 --grow + +########################################## +# Repositories + +repo --name=pp-base --baseurl=https://repo01.pixelpark.com/Linux/yum/centos/$releasever/BaseOS/$basearch/os/ +repo --name=pp-appstream --baseurl=https://repo01.pixelpark.com/Linux/yum/centos/$releasever/AppStream/$basearch/os/ +repo --name=pp-extras --baseurl=https://repo01.pixelpark.com/Linux/yum/centos/$releasever/extras/$basearch/os/ +repo --name=pp-powertools --baseurl=https://repo01.pixelpark.com/Linux/yum/centos/$releasever/PowerTools/$basearch/os/ +# repo --name=pp-epel --baseurl=https://repo01.pixelpark.com/Linux/yum/epel/$releasever/Everything/$basearch/os/ +# repo --name=pixelpark --baseurl=https://repo01.pixelpark.com/Linux/yum/pixelpark/$releasever/ + + +%packages +@core +@^minimal install +-abrt* +bc +bind-utils +curl +dosfstools +git +iotop +ksh +mailx +man +mlocate +net-tools +nfs-utils +psmisc +python3-policycoreutils +rpm-build +rsync +strace +sysstat +tcpdump +telnet +tmux +vim +wget +yum-utils +%end + +####################### +# Packages later: +# bgconf +# bgscripts-core +# colordiff +# -*firmware +# p7zip +# screen + +%post --interpreter=/usr/bin/bash + + +###################################################################################### +# Installation of pixelpark standard applications +###################################################################################### + + +### output to console +clear +POST_LOG="/var/log/post-install.log" +exec < /dev/console &> >(tee -a "$POST_LOG") + +### debug + +set -x +echo "cobbler profile = $profile_name" + +echo +echo "IP interfaces" +ip link show + +echo +echo "IP addresses" +ip address show + +echo +echo "IPv4 routes" +ip route list + +echo +echo "IPv6 routes" +ip -6 route list + + +### remove unnecessary directory +rm -rf /var/var + +export hostname="$hostname" +export system_name="$system_name" +export gateway="$gateway" +export ip_address_eth0="$ip_address_eth0" +export mac_address_eth0="$mac_address_eth0" + +echo "hostname: '$hostname'" +echo "system_name: '$system_name'" +echo "gateway: '$gateway'" +echo "ip_address_eth0: '$ip_address_eth0'" +echo "mac_address_eth0: '$mac_address_eth0'" + +%end diff --git a/lib/cr_vmware_tpl/cobbler.py b/lib/cr_vmware_tpl/cobbler.py index c9b0a7a..fc4b31d 100644 --- a/lib/cr_vmware_tpl/cobbler.py +++ b/lib/cr_vmware_tpl/cobbler.py @@ -37,7 +37,7 @@ from .config import CrTplConfiguration from .xlate import XLATOR -__version__ = '0.4.3' +__version__ = '0.4.4' LOG = logging.getLogger(__name__) @@ -616,6 +616,7 @@ class Cobbler(BaseHandler): ks_meta_list = [] ks_meta_list.append("ROOT_PWD_HASH={}".format(self.config.get_root_pwd_hash())) + ks_meta_list.append("SWAP_SIZE_MB=512") ks_meta = None if ks_meta_list: