1
0
mirror of synced 2026-05-02 22:42:51 +00:00
Files
xen-tools.xen-tools/etc/hook.d/95-create-cfg
radu ff573baf9c 2006-03-08 18:43:35 by radu
Forgot to remove testing variables.
2006-03-08 18:43:35 +00:00

31 lines
546 B
Bash
Executable File

#!/bin/sh -x
#
# This script is responsible for setting up the Xen Configuration file
prefix=$1
#
# Make sure we use ide style device names if required
#
device=sda
if [ "${use-ide}" ]; then
device=hda
fi
if [ "${dhcp}" ]; then
dyn='dhcp = "dhcp"'
fi
echo "Creating Xen configuration file in /etc/xen .. "
cat <<E_O_CFG > /etc/xen/${hostname}.cfg
kernel = '${kernel}'
memory = ${memory}
name = '${hostname}'
root = '/dev/${device}1 ro'
vif = ['']
disk = [ '$image_vbd,${device}1,w', '$swap_vbd,${device}2,w' ]
${dyn}
E_O_CFG