diff options
author | Colin Walters <walters@verbum.org> | 2010-03-14 13:32:09 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2010-03-14 13:51:55 -0400 |
commit | 8500904f5693ffb6b258cda57ed82e295ad3bebc (patch) | |
tree | aad823fd9932fb086bde3ac8fe6fdb8fc03b7e35 /fedora-virt-server.ks.in | |
parent | 2427dccc2a8d69cbb81fa1e1f74b94947e0715d5 (diff) | |
download | spin-kickstarts-8500904f5693ffb6b258cda57ed82e295ad3bebc.tar.gz spin-kickstarts-8500904f5693ffb6b258cda57ed82e295ad3bebc.tar.xz spin-kickstarts-8500904f5693ffb6b258cda57ed82e295ad3bebc.zip |
[fedora-virt-server.ks.in] New file
This is an image suitable for a fully-automated virtualized install.
Diffstat (limited to 'fedora-virt-server.ks.in')
-rw-r--r-- | fedora-virt-server.ks.in | 72 |
1 files changed, 72 insertions, 0 deletions
diff --git a/fedora-virt-server.ks.in b/fedora-virt-server.ks.in new file mode 100644 index 0000000..24375be --- /dev/null +++ b/fedora-virt-server.ks.in @@ -0,0 +1,72 @@ +# Kickstart file to create a small "base" Fedora image install suitable +# for use as e.g. an application server. +# +# Maintainer: fedora-cloud-list@fedoraproject.org +# +# REQUIRED variables: +# @@PUBLIC_KEY@@ - ssh public key +# +# You must search for all required variables and replace them. +# Example usage: +# sed -e s,@@PUBLIC_KEY@@,"$(cat ~/.ssh/authorized_keys)", fedora-virt-server.ks.in > my-fedora-server.ks + +lang C +keyboard us +timezone --utc GMT/Zulu +auth --useshadow --enablemd5 +firewall --service=ssh +bootloader --timeout=1 --append="acpi=force" +network --bootproto=dhcp --device=eth0 --onboot=on +services --enabled=network + +## IMPORTANT ## +## EDIT HERE ## +# ROOT PASSWORD: +# Setting a root password is NOT RECOMMENDED, especially if your +# server will be accessible to the public internet. This is +# because of the rise of automated ssh password guessing attacks. +# You should instead (if you don't have one already) +# generate a public ssh key: +# http://sial.org/howto/openssh/publickey-auth/ +# +# See comment below in %post for authorizing your public +# key for the root account. + +rootpw "" + +# However, if you choose instead to make a password, +# you will need to replace the above line with one like +# rootpw --iscrypted @@ROOT_PASSWORD_CRYPTED@@ +# If you do neither of these things, you will not be able to log +# into your machine. + +clearpart --all --initlabel +part / --size=550 --grow --fstype=ext4 +# You may change this if you don't want swap +part swap --recommended + +%packages +@base +%end + +# +# Add custom post scripts after the base post. +# +%post + +## EDIT HERE ## +cd /root +if ! test -d .ssh; then + mkdir --mode=700 .ssh +fi +cat >> .ssh/authorized_keys << END_AUTHORIZED_KEYS +@@PUBLIC_KEY@@ +END_AUTHORIZED_KEYS +chmod 600 .ssh/authorized_keys +if -x /usr/sbin/selinuxenabled && /usr/sbin/selinuxenabled; then + chcon -R -h -t home_ssh_t .ssh +fi + +%end + +reboot |