3 commits - generic/fedora-20-cloud.ks
by Matthew Miller
generic/fedora-20-cloud.ks | 20 +++++++-------------
1 file changed, 7 insertions(+), 13 deletions(-)
New commits:
commit aa36ef18be3681e55d1ef265e9f481ed81f62808
Author: Matthew Miller <mattdm(a)mattdm.org>
Date: Sat Oct 5 14:26:16 2013 -0400
add heat-cfntools for openstack (it's small, and makes our official images
useful as _their_ official images.
diff --git a/generic/fedora-20-cloud.ks b/generic/fedora-20-cloud.ks
index a93fdfa..62582a8 100644
--- a/generic/fedora-20-cloud.ks
+++ b/generic/fedora-20-cloud.ks
@@ -50,6 +50,9 @@ kernel
# a user account with ssh keys.
cloud-init
+# this is used by openstack's cloud orchestration framework (and it's small)
+heat-cfntools
+
# need this for growpart, because parted doesn't yet support resizepart
# https://bugzilla.redhat.com/show_bug.cgi?id=966993
cloud-utils-growpart
commit c3df27a4f11705831502415a5e03b0fe3a19383d
Author: Matthew Miller <mattdm(a)mattdm.org>
Date: Fri Oct 4 15:48:05 2013 -0400
anaconda no longer requires firewalld
https://bugzilla.redhat.com/show_bug.cgi?id=1004976
diff --git a/generic/fedora-20-cloud.ks b/generic/fedora-20-cloud.ks
index af52ee6..a93fdfa 100644
--- a/generic/fedora-20-cloud.ks
+++ b/generic/fedora-20-cloud.ks
@@ -19,9 +19,8 @@ auth --useshadow --enablemd5
selinux --enforcing
rootpw --lock --iscrypted locked
-# this is actually not used, but a static firewall
-# matching these rules is generated below.
-firewall --service=ssh
+# a static firewall allowing ssh is configured below
+firewall --disabled
bootloader --timeout=1 --append="console=ttyS0,115200n8 console=tty0" extlinux
@@ -63,11 +62,10 @@ dracut-config-generic
# by anaconda, but appliance-creator needs the hint
syslinux-extlinux
-# Needed initially, but removed below.
-firewalld
# Basic firewall. If you're going to rely on your cloud service's
-# security groups you can remove this.
+# security groups you can remove iptables-services.
+-firewalld
iptables-services
# cherry-pick a few things from @standard
@@ -133,11 +131,6 @@ echo .
echo "Removing linux-firmware package."
yum -C -y remove linux-firmware
-# Remove firewalld; was supposed to be optional in F18+, but is required to
-# be present for install/image building.
-echo "Removing firewalld."
-yum -C -y remove firewalld --setopt="clean_requirements_on_remove=1"
-
# Non-firewalld-firewall
echo -n "Writing static firewall"
cat <<EOF > /etc/sysconfig/iptables
commit 89bd5b5954282a04e3423e56d45bb76c6378e35f
Author: Matthew Miller <mattdm(a)mattdm.org>
Date: Fri Oct 4 15:26:25 2013 -0400
too-aggressive yum cleaning causing tracebacks
diff --git a/generic/fedora-20-cloud.ks b/generic/fedora-20-cloud.ks
index c085058..af52ee6 100644
--- a/generic/fedora-20-cloud.ks
+++ b/generic/fedora-20-cloud.ks
@@ -235,8 +235,6 @@ echo "Removing random-seed so it's not the same in every image."
rm -f /var/lib/random-seed
echo "Cleaning old yum repodata."
-rm -rf /var/lib/yum/yumdb/*
-rm -rf /var/lib/yum/history/*
yum history new
yum clean all
truncate -c -s 0 /var/log/yum.log
10 years, 6 months
Proposal for including heat-cfntools in Fedora cloud images
by Steven Dake
Hi,
I would like to propose an idea of including the heat-cfntools package
in the base cloud images provided by Fedora. In the past, I have been
opposed to this idea because our cfntools would conflict with AWS
cfntools. I have found a solution to this problem.
heat-cfntools places its files in /usr/bin. Amazon places their files
(with the same name) in /opt/aws/bin. The heat-cfntools package
provides a script called cfn-create-aws-symlinks which creates symlinks
in /opt/aws/bin to the cfntools in /usr/bin.
If we install heat-cfntools in the base image, heat itself can run
cfn-create-aws-symlinks as part of the bootstrapping process inside the
vm, avoiding any collisions. In effect, the symlinking would only
happen inside a Heat launched vm as part of the bootstrapping scripts we
provide.
For more details of the bootstrapping process used in Heat, please read:
http://sdake.wordpress.com/2013/03/03/how-we-use-cloudinit-in-openstack-h...
Other distros such as debian, ubuntu, SUSE, etc can follow this same
model of including heat-cfntools in their distributed qcow2 images.
This would get the heat developers out of the business of providing
prebuilt images like we do here:
http://fedorapeople.org/groups/heat/prebuilt-jeos-images/
Regards
-steve
10 years, 6 months
generic/fedora-20-cloud.ks
by Matthew Miller
generic/fedora-20-cloud.ks | 32 +++++++++++++++++---------------
1 file changed, 17 insertions(+), 15 deletions(-)
New commits:
commit a4fb2ae1bb5e9345ffc2962cbf2ba5705e37c7dd
Author: Matthew Miller <mattdm(a)mattdm.org>
Date: Fri Oct 4 15:21:13 2013 -0400
Use console=hvc0 in pvgrub configuration *only*. Also always generate that file in kickstart.
diff --git a/generic/fedora-20-cloud.ks b/generic/fedora-20-cloud.ks
index e58941b..c085058 100644
--- a/generic/fedora-20-cloud.ks
+++ b/generic/fedora-20-cloud.ks
@@ -23,7 +23,7 @@ rootpw --lock --iscrypted locked
# matching these rules is generated below.
firewall --service=ssh
-bootloader --timeout=1 --append="console=ttyS0,115200n8 console=hvc0 console=tty0" extlinux
+bootloader --timeout=1 --append="console=ttyS0,115200n8 console=tty0" extlinux
network --bootproto=dhcp --device=eth0 --onboot=on
services --enabled=network,sshd,rsyslog,iptables,cloud-init,cloud-init-local,cloud-config,cloud-final
@@ -87,20 +87,22 @@ rsync
%post --erroronfail
-# Create grub.conf for EC2.
-if [[ ! -e /boot/grub/grub.conf ]]; then
- echo -n "Creating grub.conf for pvgrub"
- rootuuid=$( awk '$2=="/" { print $1 };' /etc/fstab )
- mkdir /boot/grub
- echo -e 'default=0\ntimeout=0\n\n' > /boot/grub/grub.conf
- for kv in $( ls -1v /boot/vmlinuz* |grep -v rescue |sed s/.*vmlinuz-// ); do
- echo "title Fedora ($kv)" >> /boot/grub/grub.conf
- echo -e "\troot (hd0)" >> /boot/grub/grub.conf
- echo -e "\tkernel /boot/vmlinuz-$kv ro root=$rootuuid console=hvc0 LANG=en_US.UTF-8" >> /boot/grub/grub.conf
- echo -e "\tinitrd /boot/initramfs-$kv.img" >> /boot/grub/grub.conf
- echo
- done
-fi
+# Create grub.conf for EC2. This used to be done by appliance creator but
+# anaconda doesn't do it. And, in case appliance-creator is used, we're
+# overriding it here so that both cases get the exact same file.
+# Note that the console line is different -- that's because EC2 provides
+# different virtual hardware, and this is a convenient way to act differently
+echo -n "Creating grub.conf for pvgrub"
+rootuuid=$( awk '$2=="/" { print $1 };' /etc/fstab )
+mkdir /boot/grub
+echo -e 'default=0\ntimeout=0\n\n' > /boot/grub/grub.conf
+for kv in $( ls -1v /boot/vmlinuz* |grep -v rescue |sed s/.*vmlinuz-// ); do
+ echo "title Fedora ($kv)" >> /boot/grub/grub.conf
+ echo -e "\troot (hd0)" >> /boot/grub/grub.conf
+ echo -e "\tkernel /boot/vmlinuz-$kv ro root=$rootuuid console=hvc0 LANG=en_US.UTF-8" >> /boot/grub/grub.conf
+ echo -e "\tinitrd /boot/initramfs-$kv.img" >> /boot/grub/grub.conf
+ echo
+done
#link grub.conf to menu.lst for ec2 to work
10 years, 6 months