diff --git a/console-proxy/scripts/config_auth.sh b/console-proxy/scripts/config_auth.sh index 893920d2be2..503c90f1d0a 100755 --- a/console-proxy/scripts/config_auth.sh +++ b/console-proxy/scripts/config_auth.sh @@ -2,7 +2,12 @@ BASE_DIR="/var/www/html/copy/template/" HTACCESS="$BASE_DIR/.htaccess" + PASSWDFILE="/etc/httpd/.htpasswd" +if [ -d /etc/apache2 ] +then + PASSWDFILE="/etc/apache2/.htpasswd" +fi config_htaccess() { mkdir -p $BASE_DIR diff --git a/console-proxy/scripts/config_ssl.sh b/console-proxy/scripts/config_ssl.sh index a3be8d32dff..ef59852d69b 100755 --- a/console-proxy/scripts/config_ssl.sh +++ b/console-proxy/scripts/config_ssl.sh @@ -15,6 +15,17 @@ config_httpd_conf() { echo "" >> /etc/httpd/conf/httpd.conf } +config_apache2_conf() { + local ip=$1 + local srvr=$2 + cp -f /etc/apache2/sites-available/default.orig /etc/apache2/sites-available/default + cp -f /etc/apache2/sites-available/default-ssl.orig /etc/apache2/sites-available/default-ssl + sed -i -e "s/VirtualHost.*:80$/VirtualHost $ip:80/" /etc/httpd/conf/httpd.conf + sed -i 's/_default_/$ip/' /etc/apache2/sites-available/default-ssl + sed -i 's/ssl-cert-snakeoil.key/realhostip.key/' /etc/apache2/sites-available/default-ssl + sed -i 's/ssl-cert-snakeoil.pem/realhostip.crt/' /etc/apache2/sites-available/default-ssl +} + copy_certs() { local certdir=$(dirname $0)/certs local mydir=$(dirname $0) @@ -25,16 +36,37 @@ copy_certs() { return 1 } +copy_certs_apache2() { + local certdir=$(dirname $0)/certs + local mydir=$(dirname $0) + if [ -d $certdir ] && [ -f $certdir/realhostip.key ] && [ -f $certdir/realhostip.crt ] ; then + cp $certdir/realhostip.key /etc/ssl/private/ && cp $certdir/realhostip.crt /etc/ssl/certs/ + return $? + fi + return 1 +} + if [ $# -ne 2 ] ; then echo $"Usage: `basename $0` ipaddr servername " exit 0 fi -copy_certs +if [ -d /etc/apache2 ] +then + copy_certs_apache2 +else + copy_certs +fi + if [ $? -ne 0 ] then echo "Failed to copy certificates" exit 2 fi -config_httpd_conf $1 $2 +if [ -d /etc/apache2 ] +then + config_apache2_conf $1 $2 +else + config_httpd_conf $1 $2 +fi diff --git a/core/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java b/core/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java index 22591ae59fd..d79bfffc56c 100644 --- a/core/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java +++ b/core/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java @@ -3175,11 +3175,11 @@ public abstract class CitrixResourceBase implements StoragePoolResource, ServerR Ternary mount = mounts.get(0); - Set templates = VM.getByNameLabel(conn, "CentOS 5.3"); + Set templates = VM.getByNameLabel(conn, "Debian Lenny 5.0 (32-bit)"); if (templates.size() == 0) { - templates = VM.getByNameLabel(conn, "CentOS 5.3 (64-bit)"); + templates = VM.getByNameLabel(conn, "Debian Lenny 5.0 (32-bit)"); if (templates.size() == 0) { - String msg = " can not find template CentOS 5.3 "; + String msg = " can not find template Debian Lenny 5.0 (32-bit) "; s_logger.warn(msg); return msg; } diff --git a/tools/systemvm/debian/systemvm.xml b/tools/systemvm/debian/systemvm.xml new file mode 100644 index 00000000000..ce6ecaf6e49 --- /dev/null +++ b/tools/systemvm/debian/systemvm.xml @@ -0,0 +1,37 @@ + + systemvm2 + 1572864 + 1572864 + 1 + + hvm + + + + + + + + destroy + restart + restart + + + /usr/bin/qemu-kvm + + + + + + + + + + + + + + + + +