centos7 ks文件
[root@cobbler ks]# cat centos7.cfg
#platform=x86, AMD64, or Intel EM64T
#version=DEVEL
# Install OS instead of upgrade
install
# X Window System configuration information
xconfig --startxonboot
# Keyboard layouts
# old format: keyboard us
# new format:
keyboard --vckeymap=us --xlayouts='us'
# Halt after installation
reboot
# Root password
rootpw --iscrypted $1$L7lKtlWj$DvBzrvndeOQd7EHfRGOnj/
# System timezone
timezone Asia/Chongqing --isUtc --nontp
# Use network installation
url --url="http://192.168.3.100/cobbler/ks_mirror/centos7/"
# System language
lang en_US --addsupport=zh_CN.UTF-8
# Firewall configuration
firewall --disabled
# Network information
network --bootproto=dhcp --device=eno16777736
network --bootproto=dhcp --device=None
# System authorization information
auth --useshadow --passalgo=sha512
# Use graphical install
graphical
# Run the Setup Agent on first boot
firstboot --enable
# SELinux configuration
selinux --disabled
ignoredisk --only-use=sda
# System bootloader configuration
bootloader --location=mbr --boot-drive=sda
# Clear the Master Boot Record
zerombr
# Partition clearing information
clearpart --all --initlabel
# Disk partitioning information
part pv.10 --fstype="lvmpv" --ondisk=sda --size=35339
part /boot --fstype="xfs" --ondisk=sda --size=500
volgroup centos --pesize=4096 pv.10
logvol / --fstype="xfs" --grow --maxsize=51200 --size=1024 --name=root --vgname=centos
logvol swap --fstype="swap" --size=2064 --name=swap --vgname=centos
%packages
@base
@core
@desktop-debugging
@dial-up
@directory-client
@fonts
@guest-agents
@guest-desktop-agents
@input-methods
@internet-browser
@java-platform
@kde-desktop
@multimedia
@network-file-system-client
@print-client
@x11
%end
cobbler web界面配置
使用系统用户(pam)或者configfile定义用户登录管理cobbler web
[authentication]
#module = authn_configfile (默认值)
module = authn_pam
[root@cobbler ~]# vim /etc/cobbler/modules.conf
[root@cobbler ~]# useradd cobbler
[root@cobbler ~]# echo "cobbler" | passwd --stdin cobbler
Changing password for user cobbler.
passwd: all authentication tokens updated successfully.
[root@cobbler ~]# vim /etc/cobbler/users.conf
[admins]
admin = "cobbler"
[root@cobbler ~]# vim /etc/cobbler/modules.conf
[authentication]
module = authn_configfile
[root@cobbler ~]# htdigest /etc/cobbler/users.digest "Cobbler" admin
Adding user admin in realm Cobbler
New password:
Re-type new password: