3 # assign classes to hosts based on their hostname
6 # 51-multi-boot should have something like this
7 # for transient host configs which are not saved in
8 # git (and make it executable):
10 # if [[ ! -e /a/bin/fai/fai-wrapper ]]; then
12 # frodo) echo STABLE ;;
17 # do not use this if a menu will be presented
18 [ "$flag_menu" ] && exit 0
20 # use a list of classes for our demo machine
26 echo "DESKTOP PARTITION_PROMPT"
27 # For multi-boot system.
28 # Check that we aren't in a pxe boot environment.
29 # There is probably a better way to do this.
30 # We check the reverse condition in 51-multi-boot,
31 # and set what os we are installing, but don't check it
32 # into git since it changes regularly.
33 # It's shell looks like this:
34 # if [[ ! -e /a/bin/fai/fai-wrapper ]]; then
37 # # add more multi-boot hostnames here
41 if [[ -e /a
/bin
/fai
/fai-wrapper
]] && isdebian-stable
; then
47 if [[ -e /a
/bin
/fai
/fai-wrapper
]] && isdebian-stable
; then
48 echo "STABLE STABLE_NON_FREE"
52 echo "LINODESTABLE PARTITION_PROMPT" ;;
54 echo "LINODESTABLE PARTITION_PROMPT" ;;
56 echo "STABLE PARTITION_PROMPT" ;;
58 # echo "DEMO FAISERVER" ;;
60 # echo "DEMO XORG XFCE LVM";;
62 # echo "DEMO XORG GNOME";;
64 # echo "FAIBASE CENTOS" # you may want to add class XORG here
65 # ifclass I386 && echo CENTOS6_32 # AFAIK there's no 32bit C7
66 # ifclass AMD64 && echo CENTOS7_64
67 # exit 0 ;; # CentOS does not use the GRUB class
69 # # Scientific Linux Cern, is very similar to CentOS. SLC should alsways use the class CENTOS
70 # echo "FAIBASE CENTOS SLC" # you may want to add class XORG here
71 # ifclass I386 && echo SLC7_32
72 # ifclass AMD64 && echo SLC7_64
73 # exit 0 ;; # CentOS/SLC does not use the GRUB class
78 if grep ^
52:54:00: /sys
/class
/net
/eth
0/address
&>/dev
/null
; then
79 # if our eth0 mac is in the kvm range, we are a vm.