diff options
| author | Bastian Wissler | 2009-02-26 17:37:43 +0100 |
|---|---|---|
| committer | Bastian Wissler | 2009-02-26 17:37:43 +0100 |
| commit | 8c7b7ce9955d98f11d251da025a7dec8d230f46f (patch) | |
| tree | 5cfcf5b698099ed3433d49a4eb3ecaebfa90372c /os-plugins/plugins/vmchooser | |
| parent | Further improvements for run-virt.sh ... (diff) | |
| download | core-8c7b7ce9955d98f11d251da025a7dec8d230f46f.tar.gz core-8c7b7ce9955d98f11d251da025a7dec8d230f46f.tar.xz core-8c7b7ce9955d98f11d251da025a7dec8d230f46f.zip | |
vmchooser:
* various changes to run-virt.sh
* new vmchooser binary puts path of xml file to image_name node
xserver:
* suse-gfx-install: new link for ati drivers
* XX_xserver: fixed path
git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@2645 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'os-plugins/plugins/vmchooser')
| -rw-r--r-- | os-plugins/plugins/vmchooser/files/run-virt.sh | 19 | ||||
| -rw-r--r-- | os-plugins/plugins/vmchooser/files/vmchooser | bin | 658532 -> 658596 bytes |
2 files changed, 8 insertions, 11 deletions
diff --git a/os-plugins/plugins/vmchooser/files/run-virt.sh b/os-plugins/plugins/vmchooser/files/run-virt.sh index 759709e2..0a9919c2 100644 --- a/os-plugins/plugins/vmchooser/files/run-virt.sh +++ b/os-plugins/plugins/vmchooser/files/run-virt.sh @@ -29,32 +29,29 @@ xml=$1 [ -e "${xml}" ] || { echo -e "\n\tNo XML file given!\n"; exit 1; } -# path to the xml file(just take the path to the xml file) -imagepath=${xml%/*} - # Read needed variables from XML file ############################################################################### # file name of the image -imagename=$(grep -i "<image_name param=\"" ${xml} | awk -F "\"" '{ print $2 }') -diskfile=$imagepath/$imagename +imagename=$(grep -io "<image_name param=.*\"" ${xml} | awk -F "\"" '{ print $2 }') +diskfile=$imagename [ -e $diskfile ] || { echo -e "\n\tImage file $diskfile not found!"; exit 1; } # short description of the image (as present in the vmchooser menu line) -short_description=$(grep "short_description param=\"" ${xml} | \ +short_description=$(grep -o "short_description param=.*\"" ${xml} | \ sed -e "s/&.*;/; /g" | awk -F "\"" '{print $2}') # if ${short_description} not defined use ${image_name} short_description=${short_description:-"${image_name}"} displayname=${short_description} # type of virtual machine to run -virt_mach=$(grep "virtualmachine param=\"" ${xml} | \ +virt_mach=$(grep -o "virtualmachine param=.*\"" ${xml} | \ sed -e "s/&.*;/; /g" | awk -F "\"" '{print $2}') # make a guess from the filename extension if ${virt_mach} is empty (not set # within the xml file) if [ -z ${virt_mach} ] ; then - case "${imagename#*.}" in + case "${imagename##*.}" in vmdk|VMDK) virt_mach="vmware" ;; @@ -68,13 +65,13 @@ if [ -z ${virt_mach} ] ; then fi # definition of the client system -vmostype=$(grep -i "<os param=\"" ${xml} | awk -F "\"" '{ print $2 }') +vmostype=$(grep -io "<os param=\"" ${xml} | awk -F "\"" '{ print $2 }') # definition of the networking the client system is connected to -network_kind=$(grep -i "<network param=\"" ${xml} | awk -F "\"" '{ print $2 }') +network_kind=$(grep -io "<network param=\"" ${xml} | awk -F "\"" '{ print $2 }') # serial port defined (e.g. "ttyS0" or "autodetect") -serial=$(grep -i "<serial port=\"" ${xml} | awk -F "\"" '{ print $2 }') +serial=$(grep -io "<serial port=\"" ${xml} | awk -F "\"" '{ print $2 }') # declaration of default variables diff --git a/os-plugins/plugins/vmchooser/files/vmchooser b/os-plugins/plugins/vmchooser/files/vmchooser Binary files differindex 2518b774..2a91665c 100644 --- a/os-plugins/plugins/vmchooser/files/vmchooser +++ b/os-plugins/plugins/vmchooser/files/vmchooser |
