[Fai-commit] r4465 - in people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo: class files/boot/grub files/boot/grub/grub.conf files/boot/grub/menu.lst files/etc/fstab files/etc/init.d/tomcat hooks package_config scripts scripts/RHEL-DEMO-NAMESERVER scripts/RHEL-DEMO-TOMCAT scripts/RHEL-DEMO-WEBSERVER
lazyboy-guest at alioth.debian.org
lazyboy-guest at alioth.debian.org
Fri Jul 20 10:33:59 UTC 2007
Author: lazyboy-guest
Date: 2007-07-20 10:33:59 +0000 (Fri, 20 Jul 2007)
New Revision: 4465
Added:
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/rhel5-demo-dns.var
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/RHEL-DEMO-KERNEL
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/postinst
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/RHEL-DEMO-KERNEL
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/XENU
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/finish.RHEL-NETINSTALL
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-KERNEL
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-NAMESERVER/
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-NAMESERVER/20-enable-named
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-TOMCAT/99-start-restart
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-WEBSERVER/99-start-restart
Removed:
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/GRUB
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/RHEL-DEMO-COMMON
Modified:
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/50-host-classes
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/init.d/tomcat/RHEL-DEMO-TOMCAT
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/prepareapt.DIST-RHEL_5
people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-NAMESERVER
Log:
final stuff to get demo with netinstall working (only manual install of missing packages in nfsroot still necessary)
Modified: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/50-host-classes
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/50-host-classes 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/50-host-classes 2007-07-20 10:33:59 UTC (rev 4465)
@@ -4,43 +4,23 @@
# use a list of classes for our demo machine
case $HOSTNAME in
- faiserver)
- echo "FAIBASE DEMO FAISERVER" ;;
- demohost)
- echo "FAIBASE DHCPC DEMO" ;;
- gnomehost)
- echo "FAIBASE DHCPC DEMO XORG GNOME";;
- atom*)
- echo "FAIBASE DHCPC DEMO" ;;
- rhel5-demo)
- #echo "DIST-RHEL_5 FAIBASE DHCPC XENU" ;;
- # TODO: uebersichlicher formatieren
- echo "DEBUG DIST-RHEL_5 FAIBASE DHCPC"
- echo "RHEL-DEMO-COMMON RHEL-DEMO-DBSERVER RHEL-DEMO-NAMESERVER RHEL-DEMO-SOFTUPDATE RHEL-DEMO-TOMCAT RHEL-DEMO-WEBSERVER"
- echo "XENU"
- ;;
rhel5-demo-web)
echo "DEBUG DIST-RHEL_5 FAIBASE DHCPC"
echo "RHEL-DEMO-COMMON RHEL-DEMO-SOFTUPDATE RHEL-DEMO-TOMCAT RHEL-DEMO-WEBSERVER"
echo "XENU"
;;
-
rhel5-demo-dns)
echo "DEBUG DIST-RHEL_5 FAIBASE DHCPC"
echo "RHEL-DEMO-COMMON RHEL-DEMO-NAMESERVER RHEL-DEMO-SOFTUPDATE"
- echo "XENU"
+ echo "RHEL-DEMO-KERNEL RHEL-NETINSTALL"
;;
rhel5-demo-db)
echo "DEBUG DIST-RHEL_5 FAIBASE DHCPC"
- echo "RHEL-DEMO-COMMON RHEL-DEMO-DBSERVER RHEL-DEMO-SOFTUPDATE"
+ echo "RHEL-DEMO-COMMON RHEL-DEMO-DBSERVER RHEL-DEMO-SOFTUPDATE RHEL-DEMO-WEBSERVER"
echo "XENU"
;;
-
-
- xen-tools-test)
- echo "FAIBASE DHCPC XENU" ;;
*)
- echo "FAIBASE DHCPC BLA" ;;
+ echo "FAIBASE DHCPC" ;;
esac
(ifclass I386 || ifclass AMD64) && echo GRUB
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/rhel5-demo-dns.var
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/rhel5-demo-dns.var (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/class/rhel5-demo-dns.var 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1 @@
+FAI_ACTION=install
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/RHEL-DEMO-KERNEL
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/RHEL-DEMO-KERNEL (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/RHEL-DEMO-KERNEL 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,9 @@
+#
+timeout 5
+default 0
+color cyan/blue white/blue
+
+title RHEL5
+ root (hd0,0)
+ kernel /boot/vmlinuz-2.6.18-8.el5 root=/dev/sda1 ro
+ initrd /boot/initrd-2.6.18-8.el5.img
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/postinst
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/postinst (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/grub.conf/postinst 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,25 @@
+#! /bin/bash
+
+error=0 ; trap "error=$((error|1))" ERR
+
+set -a
+
+# during softupdate use this file
+[ -r $target/var/log/fai/disk_var.sh ] && . $target/var/log/fai/disk_var.sh
+
+# if class NOMBR is defined, write boot loader into root partition, not into mbr
+ifclass NOMBR && BOOT_DEVICE=$BOOT_PARTITION
+
+if [ ! -z $BOOT_DEVICE ]; then
+ grub-install --no-floppy --root-directory=$target $BOOT_DEVICE
+ GROOT=$(device2grub $BOOT_PARTITION)
+ perl -pi -e 's/#(\w+)#/$ENV{$1}/' $2
+ ifclass DIST-DEBIAN && $ROOTCMD /usr/sbin/update-grub
+ # TODO: how to update grub on other distributions?
+ echo "Grub installed on $BOOT_DEVICE on $GROOT"
+else
+ echo "BOOT_DEVICE empty - not running grub-instll"
+fi
+
+exit $error
+
Deleted: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/GRUB
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/GRUB 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/GRUB 2007-07-20 10:33:59 UTC (rev 4465)
@@ -1,43 +0,0 @@
-#
-timeout 5
-default 0
-color cyan/blue white/blue
-
-### BEGIN AUTOMAGIC KERNELS LIST
-## lines between the AUTOMAGIC KERNELS LIST markers will be modified
-## by the debian update-grub script except for the default optons below
-
-## DO NOT UNCOMMENT THEM, Just edit them to your needs
-
-## ## Start Default Options ##
-## default kernel options
-# kopt=root=#ROOT_PARTITION# ro
-
-## default grub root device
-## e.g. groot=(hd0,0)
-# groot=#GROOT#
-
-## should update-grub create alternative boot options
-## e.g. alternative=true
-## alternative=false
-# alternative=true
-
-## should update-grub lock alternative boot options
-## e.g. lockalternative=true
-## lockalternative=false
-# lockalternative=true
-
-## altoption boot targets option
-## multiple altoptions lines are allowed
-## e.g. altoptions=(extra menu suffix) extra boot options
-## altoptions=(recovery mode) single
-# altoptions=(recovery mode) single
-
-## add memtest86 if found
-# memtest86=true
-
-## ## End Default Options ##
-
-### END DEBIAN AUTOMAGIC KERNELS LIST
-
-
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/RHEL-DEMO-KERNEL
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/RHEL-DEMO-KERNEL (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/boot/grub/menu.lst/RHEL-DEMO-KERNEL 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,9 @@
+#
+timeout 5
+default 0
+color cyan/blue white/blue
+
+title RHEL5
+ root (hd0,0)
+ kernel /boot/vmlinuz-2.6.18-8.el5 root=/dev/sda1 ro
+ initrd /boot/initrd-2.6.18-8.el5.img
Deleted: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/RHEL-DEMO-COMMON
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/RHEL-DEMO-COMMON 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/RHEL-DEMO-COMMON 2007-07-20 10:33:59 UTC (rev 4465)
@@ -1,7 +0,0 @@
-/dev/sda1 / ext3 defaults 1 1
-/dev/sda2 swap swap defaults 0 0
-none /dev/pts devpts gid=5,mode=620 0 0
-none /dev/shm tmpfs defaults 0 0
-none /proc proc defaults 0 0
-none /sys sysfs defaults 0 0
-
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/XENU
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/XENU (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/fstab/XENU 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,7 @@
+/dev/sda1 / ext3 defaults 1 1
+/dev/sda2 swap swap defaults 0 0
+none /dev/pts devpts gid=5,mode=620 0 0
+none /dev/shm tmpfs defaults 0 0
+none /proc proc defaults 0 0
+none /sys sysfs defaults 0 0
+
Modified: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/init.d/tomcat/RHEL-DEMO-TOMCAT
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/init.d/tomcat/RHEL-DEMO-TOMCAT 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/files/etc/init.d/tomcat/RHEL-DEMO-TOMCAT 2007-07-20 10:33:59 UTC (rev 4465)
@@ -52,6 +52,7 @@
;;
restart)
stop
+ sleep 10
start
;;
*)
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/finish.RHEL-NETINSTALL
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/finish.RHEL-NETINSTALL (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/finish.RHEL-NETINSTALL 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,6 @@
+#! /bin/bash
+
+umount $target/proc
+
+umount $target/sys
+
Modified: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/prepareapt.DIST-RHEL_5
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/prepareapt.DIST-RHEL_5 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/hooks/prepareapt.DIST-RHEL_5 2007-07-20 10:33:59 UTC (rev 4465)
@@ -1,5 +1,12 @@
#! /bin/bash
-# TODO: copy all yum files
+# copy all yum files, and make sure Core is installed
+
+ifclass RHEL-NETINSTALL && {
+ mount -o bind /proc $target/proc
+ mount -o bind /sys $target/sys
+}
+
fcopy -r /etc/yum.repos.d/
+$ROOTCMD yum groupinstall -y Core
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-KERNEL
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-KERNEL (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-KERNEL 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,3 @@
+PACKAGES yumi
+kernel
+grub
Modified: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-NAMESERVER
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-NAMESERVER 2007-07-19 13:41:27 UTC (rev 4464)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/package_config/RHEL-DEMO-NAMESERVER 2007-07-20 10:33:59 UTC (rev 4465)
@@ -1,2 +1,3 @@
PACKAGES yumi
bind
+caching-nameserver
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-NAMESERVER/20-enable-named
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-NAMESERVER/20-enable-named (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-NAMESERVER/20-enable-named 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,3 @@
+#! /bin/bash
+
+$ROOTCMD chkconfig named on
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-TOMCAT/99-start-restart
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-TOMCAT/99-start-restart (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-TOMCAT/99-start-restart 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,14 @@
+#! /bin/bash
+
+# we want ro reboot tomcat when it's running
+if [ ! -z "`ps ax | grep tomcat`" ]; then
+ echo "restarting tomcat after update"
+ /etc/init.d/tomcat restart
+ exit 0
+fi
+
+if [ $FAI_ACTION=="softupdate" ]; then
+ echo "starting tomcat after update"
+ /etc/init.d/tomcat start
+fi
+
Added: people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-WEBSERVER/99-start-restart
===================================================================
--- people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-WEBSERVER/99-start-restart (rev 0)
+++ people/lazyboy/rhel-install-fixes_3.1.8/examples/rhel-install-demo/scripts/RHEL-DEMO-WEBSERVER/99-start-restart 2007-07-20 10:33:59 UTC (rev 4465)
@@ -0,0 +1,16 @@
+#! /bin/bash
+
+# start when softupdate, reboot when already running
+
+# we want ro reboot http when it's running
+if [ ! -z "`ps ax | grep httpd`" ]; then
+ echo "restarting httpd after update"
+ /etc/init.d/httpd restart
+ exit 0
+fi
+
+if [ $FAI_ACTION=="softupdate" ]; then
+ echo "starting httpd after update
+ /etc/init.d/httpd start
+fi
+
More information about the Fai-commit
mailing list