2009-01-02 17:58:51 +03:00
#!/bin/bash
2009-01-19 21:05:46 +03:00
# -------------------------------------------------------------------------- #
2010-02-22 20:00:30 +03:00
# Copyright 2002-2010, OpenNebula Project Leads (OpenNebula.org) #
2009-01-19 21:05:46 +03:00
# #
# Licensed under the Apache License, Version 2.0 (the "License"); you may #
# not use this file except in compliance with the License. You may obtain #
# a copy of the License at #
# #
# http://www.apache.org/licenses/LICENSE-2.0 #
# #
# Unless required by applicable law or agreed to in writing, software #
# distributed under the License is distributed on an "AS IS" BASIS, #
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
# See the License for the specific language governing permissions and #
# limitations under the License. #
#--------------------------------------------------------------------------- #
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Install program for OpenNebula. It will install it relative to
2010-07-11 22:39:10 +04:00
# $ONE_LOCATION if defined with the -d option, otherwise it'll be installed
2009-01-02 17:58:51 +03:00
# under /. In this case you may specified the oneadmin user/group, so you do
# not need run the OpenNebula daemon with root priviledges
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
# COMMAND LINE PARSING
#-------------------------------------------------------------------------------
usage( ) {
echo
2010-07-11 22:39:10 +04:00
echo "Usage: install.sh [-u install_user] [-g install_group] [-k keep conf]"
2009-10-22 15:20:27 +04:00
echo " [-d ONE_LOCATION] [-c occi|ec2] [-r] [-h]"
2010-07-11 22:39:10 +04:00
echo
2009-01-02 17:58:51 +03:00
echo "-u: user that will run opennebula, defults to user executing install.sh"
echo "-g: group of the user that will run opennebula, defults to user"
echo " executing install.sh"
2010-11-12 16:12:12 +03:00
echo "-k: keep configuration files of existing OpenNebula installation, useful"
2011-02-10 21:29:35 +03:00
echo " when upgrading. This flag should not be set when installing"
2010-11-12 16:12:12 +03:00
echo " OpenNebula for the first time"
2010-07-27 17:51:05 +04:00
echo "-d: target installation directory, if not defined it'd be root. Must be"
echo " an absolute path."
2011-02-10 17:57:11 +03:00
echo "-c: install client utilities: OpenNebula cli, occi and ec2 client files"
2011-02-23 19:27:17 +03:00
echo "-s: install OpenNebula Sunstone"
2009-01-02 17:58:51 +03:00
echo "-r: remove Opennebula, only useful if -d was not specified, otherwise"
echo " rm -rf \$ONE_LOCATION would do the job"
2009-08-27 21:25:39 +04:00
echo "-l: creates symlinks instead of copying files, useful for development"
2009-01-02 17:58:51 +03:00
echo "-h: prints this help"
2008-06-17 20:27:32 +04:00
}
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
2008-06-17 20:27:32 +04:00
2011-02-23 19:27:17 +03:00
TEMP_OPT = ` getopt -o hkrlcsu:g:d: -n 'install.sh' -- " $@ " `
2008-06-17 20:27:32 +04:00
2010-07-11 22:39:10 +04:00
if [ $? != 0 ] ; then
2009-01-02 17:58:51 +03:00
usage
exit 1
2008-06-17 20:27:32 +04:00
fi
2009-01-02 17:58:51 +03:00
eval set -- " $TEMP_OPT "
2008-07-17 23:42:17 +04:00
2009-01-02 17:58:51 +03:00
INSTALL_ETC = "yes"
UNINSTALL = "no"
2009-08-27 21:25:39 +04:00
LINK = "no"
2009-09-25 22:18:50 +04:00
CLIENT = "no"
2011-02-23 19:27:17 +03:00
SUNSTONE = "no"
2009-01-02 17:58:51 +03:00
ONEADMIN_USER = ` id -u`
ONEADMIN_GROUP = ` id -g`
SRC_DIR = $PWD
2008-11-13 19:21:17 +03:00
2009-01-02 17:58:51 +03:00
while true ; do
case " $1 " in
-h) usage; exit 0; ;
-k) INSTALL_ETC = "no" ; shift ; ;
-r) UNINSTALL = "yes" ; shift ; ;
2009-08-27 21:25:39 +04:00
-l) LINK = "yes" ; shift ; ;
2011-02-23 19:27:17 +03:00
-c) CLIENT = "yes" ; INSTALL_ETC = "no" ; shift ; ;
-s) SUNSTONE = "yes" ; INSTALL_ETC = "no" ; shift ; ;
2009-01-02 17:58:51 +03:00
-u) ONEADMIN_USER = " $2 " ; shift 2; ;
-g) ONEADMIN_GROUP = " $2 " ; shift 2; ;
2009-01-19 19:40:46 +03:00
-d) ROOT = " $2 " ; shift 2 ; ;
2009-01-02 17:58:51 +03:00
--) shift ; break ; ;
*) usage; exit 1 ; ;
esac
done
2008-11-13 19:21:17 +03:00
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Definition of locations
#-------------------------------------------------------------------------------
2009-01-19 19:40:46 +03:00
if [ -z " $ROOT " ] ; then
2009-01-02 17:58:51 +03:00
BIN_LOCATION = "/usr/bin"
LIB_LOCATION = "/usr/lib/one"
ETC_LOCATION = "/etc/one"
LOG_LOCATION = "/var/log/one"
VAR_LOCATION = "/var/lib/one"
2011-02-23 19:27:17 +03:00
SUNSTONE_LOCATION = " $LIB_LOCATION /sunstone "
2010-07-22 20:20:12 +04:00
IMAGES_LOCATION = " $VAR_LOCATION /images "
2009-01-02 17:58:51 +03:00
RUN_LOCATION = "/var/run/one"
2009-12-12 18:35:04 +03:00
LOCK_LOCATION = "/var/lock/one"
2009-01-02 17:58:51 +03:00
INCLUDE_LOCATION = "/usr/include"
2010-08-02 13:24:01 +04:00
SHARE_LOCATION = "/usr/share/one"
2010-10-14 19:24:01 +04:00
MAN_LOCATION = "/usr/share/man/man8"
2010-07-11 22:39:10 +04:00
2011-02-23 19:27:17 +03:00
if [ " $CLIENT " = "yes" ] ; then
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION "
DELETE_DIRS = ""
CHOWN_DIRS = ""
elif [ " $SUNSTONE " = "yes" ] ; then
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION $VAR_LOCATION $SUNSTONE_LOCATION "
DELETE_DIRS = " $MAKE_DIRS "
CHOWN_DIRS = ""
else
2009-09-25 22:18:50 +04:00
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION $ETC_LOCATION $VAR_LOCATION \
$INCLUDE_LOCATION $SHARE_LOCATION \
2010-10-14 19:24:01 +04:00
$LOG_LOCATION $RUN_LOCATION $LOCK_LOCATION \
$IMAGES_LOCATION $MAN_LOCATION "
2010-07-11 22:39:10 +04:00
2009-09-25 22:18:50 +04:00
DELETE_DIRS = " $LIB_LOCATION $ETC_LOCATION $LOG_LOCATION $VAR_LOCATION \
$RUN_LOCATION $SHARE_DIRS "
2009-12-12 18:35:04 +03:00
CHOWN_DIRS = " $LOG_LOCATION $VAR_LOCATION $RUN_LOCATION $LOCK_LOCATION "
2009-09-25 22:18:50 +04:00
fi
2009-05-07 19:23:13 +04:00
2009-01-02 17:58:51 +03:00
else
2009-01-19 19:40:46 +03:00
BIN_LOCATION = " $ROOT /bin "
LIB_LOCATION = " $ROOT /lib "
ETC_LOCATION = " $ROOT /etc "
VAR_LOCATION = " $ROOT /var "
2011-02-23 19:27:17 +03:00
SUNSTONE_LOCATION = " $LIB_LOCATION /sunstone "
2010-07-22 20:20:12 +04:00
IMAGES_LOCATION = " $VAR_LOCATION /images "
2009-01-19 19:40:46 +03:00
INCLUDE_LOCATION = " $ROOT /include "
SHARE_LOCATION = " $ROOT /share "
2010-10-14 19:24:01 +04:00
MAN_LOCATION = " $ROOT /share/man/man8 "
2009-01-02 17:58:51 +03:00
2011-02-23 19:27:17 +03:00
if [ " $CLIENT " = "yes" ] ; then
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION "
DELETE_DIRS = " $MAKE_DIRS "
elif [ " $SUNSTONE " = "yes" ] ; then
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION $VAR_LOCATION $SUNSTONE_LOCATION "
DELETE_DIRS = " $MAKE_DIRS "
else
2009-09-25 22:18:50 +04:00
MAKE_DIRS = " $BIN_LOCATION $LIB_LOCATION $ETC_LOCATION $VAR_LOCATION \
2010-10-14 19:24:01 +04:00
$INCLUDE_LOCATION $SHARE_LOCATION $IMAGES_LOCATION \
$MAN_LOCATION "
2010-07-11 22:39:10 +04:00
2009-09-25 22:18:50 +04:00
DELETE_DIRS = " $MAKE_DIRS "
CHOWN_DIRS = " $ROOT "
fi
2009-01-02 17:58:51 +03:00
2009-01-19 19:40:46 +03:00
CHOWN_DIRS = " $ROOT "
2009-01-02 17:58:51 +03:00
fi
2008-11-13 19:21:17 +03:00
2009-01-02 17:58:51 +03:00
SHARE_DIRS = " $SHARE_LOCATION /examples \
2009-07-21 14:45:54 +04:00
$SHARE_LOCATION /examples/tm \
$SHARE_LOCATION /hooks"
2009-01-02 17:58:51 +03:00
ETC_DIRS = " $ETC_LOCATION /im_kvm \
$ETC_LOCATION /im_xen \
$ETC_LOCATION /im_ec2 \
$ETC_LOCATION /vmm_ec2 \
2010-09-29 14:07:20 +04:00
$ETC_LOCATION /vmm_ssh \
2010-09-30 19:16:31 +04:00
$ETC_LOCATION /vmm_sh \
2009-01-02 17:58:51 +03:00
$ETC_LOCATION /tm_nfs \
$ETC_LOCATION /tm_ssh \
2009-04-04 03:34:33 +04:00
$ETC_LOCATION /tm_dummy \
2009-10-16 17:50:56 +04:00
$ETC_LOCATION /tm_lvm \
2009-07-21 18:56:35 +04:00
$ETC_LOCATION /hm \
2010-07-09 20:59:42 +04:00
$ETC_LOCATION /auth \
2009-09-03 22:10:55 +04:00
$ETC_LOCATION /ec2query_templates \
$ETC_LOCATION /occi_templates"
2009-01-02 17:58:51 +03:00
2010-11-16 14:29:14 +03:00
LIB_DIRS = " $LIB_LOCATION /ruby \
2009-07-09 18:34:34 +04:00
$LIB_LOCATION /ruby/OpenNebula \
2009-10-12 03:06:46 +04:00
$LIB_LOCATION /ruby/cloud/ \
$LIB_LOCATION /ruby/cloud/econe \
$LIB_LOCATION /ruby/cloud/econe/views \
$LIB_LOCATION /ruby/cloud/occi \
2009-01-02 17:58:51 +03:00
$LIB_LOCATION /tm_commands \
$LIB_LOCATION /tm_commands/nfs \
$LIB_LOCATION /tm_commands/ssh \
$LIB_LOCATION /tm_commands/dummy \
2009-10-16 17:50:56 +04:00
$LIB_LOCATION /tm_commands/lvm \
2010-11-24 18:27:07 +03:00
$LIB_LOCATION /mads \
$LIB_LOCATION /remotes \
$LIB_LOCATION /remotes/im \
$LIB_LOCATION /remotes/im/kvm.d \
$LIB_LOCATION /remotes/im/xen.d \
2011-02-10 21:29:35 +03:00
$LIB_LOCATION /remotes/im/ganglia.d \
2010-11-24 18:27:07 +03:00
$LIB_LOCATION /remotes/vmm/xen \
$LIB_LOCATION /remotes/vmm/kvm"
2009-01-02 17:58:51 +03:00
2010-11-16 14:29:14 +03:00
VAR_DIRS = " $VAR_LOCATION /remotes \
$VAR_LOCATION /remotes/im \
$VAR_LOCATION /remotes/im/kvm.d \
$VAR_LOCATION /remotes/im/xen.d \
2011-02-10 21:29:35 +03:00
$VAR_LOCATION /remotes/im/ganglia.d \
2010-11-16 14:29:14 +03:00
$VAR_LOCATION /remotes/vmm/xen \
$VAR_LOCATION /remotes/vmm/kvm"
2011-02-23 19:27:17 +03:00
SUNSTONE_DIRS = " $SUNSTONE_LOCATION /models \
$SUNSTONE_LOCATION /models/OpenNebulaJSON \
$SUNSTONE_LOCATION /public \
$SUNSTONE_LOCATION /public/js \
$SUNSTONE_LOCATION /public/js/vendor \
$SUNSTONE_LOCATION /public/css \
$SUNSTONE_LOCATION /public/css/vendor \
$SUNSTONE_LOCATION /public/images \
$SUNSTONE_LOCATION /templates"
2009-10-22 15:20:27 +04:00
LIB_ECO_CLIENT_DIRS = " $LIB_LOCATION /ruby \
2011-02-10 17:57:11 +03:00
$LIB_LOCATION /ruby/OpenNebula \
2009-10-22 15:20:27 +04:00
$LIB_LOCATION /ruby/cloud/ \
$LIB_LOCATION /ruby/cloud/econe"
LIB_OCCI_CLIENT_DIRS = " $LIB_LOCATION /ruby \
2011-02-10 17:57:11 +03:00
$LIB_LOCATION /ruby/OpenNebula \
2009-10-22 15:20:27 +04:00
$LIB_LOCATION /ruby/cloud/occi"
2009-09-25 22:18:50 +04:00
2011-02-23 19:27:17 +03:00
LIB_OCA_CLIENT_DIRS = " $LIB_LOCATION /ruby \
$LIB_LOCATION /ruby/OpenNebula"
2011-02-10 17:57:11 +03:00
LIB_CLI_DIRS = " $LIB_LOCATION /ruby \
$LIB_LOCATION /ruby/OpenNebula"
2011-02-23 19:27:17 +03:00
if [ " $CLIENT " = "yes" ] ; then
2011-02-10 17:57:11 +03:00
MAKE_DIRS = " $MAKE_DIRS $LIB_ECO_CLIENT_DIRS $LIB_OCCI_CLIENT_DIRS \
$LIB_CLI_DIRS "
2011-02-23 19:27:17 +03:00
elif [ " $SUNSTONE " = "yes" ] ; then
MAKE_DIRS = " $MAKE_DIRS $SUNSTONE_DIRS $LIB_OCA_CLIENT_DIRS "
else
MAKE_DIRS = " $MAKE_DIRS $SHARE_DIRS $ETC_DIRS $LIB_DIRS $VAR_DIRS $SUNSTONE_DIRS "
2009-09-25 22:18:50 +04:00
fi
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
# FILE DEFINITION, WHAT IS GOING TO BE INSTALLED AND WHERE
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
2011-02-10 20:16:18 +03:00
INSTALL_FILES = (
BIN_FILES:$BIN_LOCATION
INCLUDE_FILES:$INCLUDE_LOCATION
LIB_FILES:$LIB_LOCATION
RUBY_LIB_FILES:$LIB_LOCATION /ruby
RUBY_OPENNEBULA_LIB_FILES:$LIB_LOCATION /ruby/OpenNebula
MADS_LIB_FILES:$LIB_LOCATION /mads
IM_PROBES_FILES:$VAR_LOCATION /remotes/im
IM_PROBES_KVM_FILES:$VAR_LOCATION /remotes/im/kvm.d
IM_PROBES_XEN_FILES:$VAR_LOCATION /remotes/im/xen.d
2011-02-10 21:29:35 +03:00
IM_PROBES_GANGLIA_FILES:$VAR_LOCATION /remotes/im/ganglia.d
2011-02-10 20:16:18 +03:00
VMM_SSH_KVM_SCRIPTS:$VAR_LOCATION /remotes/vmm/kvm
VMM_SSH_XEN_SCRIPTS:$VAR_LOCATION /remotes/vmm/xen
2011-02-10 21:29:35 +03:00
VMM_SSH_XEN_KVM_POLL:$VAR_LOCATION /remotes/vmm/kvm/poll
VMM_SSH_XEN_KVM_POLL:$VAR_LOCATION /remotes/vmm/xen/poll
VMM_SSH_GANGLIA_POLL:$VAR_LOCATION /remotes/vmm/kvm/poll_local
VMM_SSH_GANGLIA_POLL:$VAR_LOCATION /remotes/vmm/xen/poll_local
2011-02-10 20:16:18 +03:00
IM_PROBES_FILES:$LIB_LOCATION /remotes/im
IM_PROBES_KVM_FILES:$LIB_LOCATION /remotes/im/kvm.d
IM_PROBES_XEN_FILES:$LIB_LOCATION /remotes/im/xen.d
2011-02-10 21:29:35 +03:00
IM_PROBES_GANGLIA_FILES:$LIB_LOCATION /remotes/im/ganglia.d
2011-02-10 20:16:18 +03:00
VMM_SSH_KVM_SCRIPTS:$LIB_LOCATION /remotes/vmm/kvm
VMM_SSH_XEN_SCRIPTS:$LIB_LOCATION /remotes/vmm/xen
2011-02-10 21:29:35 +03:00
VMM_SSH_XEN_KVM_POLL:$LIB_LOCATION /remotes/vmm/kvm/poll
VMM_SSH_XEN_KVM_POLL:$LIB_LOCATION /remotes/vmm/xen/poll
VMM_SSH_GANGLIA_POLL:$LIB_LOCATION /remotes/vmm/kvm/poll_local
VMM_SSH_GANGLIA_POLL:$LIB_LOCATION /remotes/vmm/xen/poll_local
2011-02-10 20:16:18 +03:00
NFS_TM_COMMANDS_LIB_FILES:$LIB_LOCATION /tm_commands/nfs
SSH_TM_COMMANDS_LIB_FILES:$LIB_LOCATION /tm_commands/ssh
DUMMY_TM_COMMANDS_LIB_FILES:$LIB_LOCATION /tm_commands/dummy
LVM_TM_COMMANDS_LIB_FILES:$LIB_LOCATION /tm_commands/lvm
EXAMPLE_SHARE_FILES:$SHARE_LOCATION /examples
TM_EXAMPLE_SHARE_FILES:$SHARE_LOCATION /examples/tm
HOOK_SHARE_FILES:$SHARE_LOCATION /hooks
COMMON_CLOUD_LIB_FILES:$LIB_LOCATION /ruby/cloud
ECO_LIB_FILES:$LIB_LOCATION /ruby/cloud/econe
ECO_LIB_VIEW_FILES:$LIB_LOCATION /ruby/cloud/econe/views
ECO_BIN_FILES:$BIN_LOCATION
OCCI_LIB_FILES:$LIB_LOCATION /ruby/cloud/occi
OCCI_BIN_FILES:$BIN_LOCATION
MAN_FILES:$MAN_LOCATION
)
INSTALL_CLIENT_FILES = (
COMMON_CLOUD_CLIENT_LIB_FILES:$LIB_LOCATION /ruby/cloud
ECO_LIB_CLIENT_FILES:$LIB_LOCATION /ruby/cloud/econe
ECO_BIN_CLIENT_FILES:$BIN_LOCATION
COMMON_CLOUD_CLIENT_LIB_FILES:$LIB_LOCATION /ruby/cloud
OCCI_LIB_CLIENT_FILES:$LIB_LOCATION /ruby/cloud/occi
OCCI_BIN_CLIENT_FILES:$BIN_LOCATION
CLI_BIN_FILES:$BIN_LOCATION
CLI_LIB_FILES:$LIB_LOCATION /ruby
RUBY_OPENNEBULA_LIB_FILES:$LIB_LOCATION /ruby/OpenNebula
)
2011-02-24 14:28:57 +03:00
INSTALL_SUNSTONE_RUBY_FILES = (
SUNSTONE_RUBY_LIB_FILES:$LIB_LOCATION /ruby
RUBY_OPENNEBULA_LIB_FILES:$LIB_LOCATION /ruby/OpenNebula
)
2011-02-23 19:27:17 +03:00
INSTALL_SUNSTONE_FILES = (
SUNSTONE_FILES:$SUNSTONE_LOCATION
SUNSTONE_BIN_FILES:$BIN_LOCATION
SUNSTONE_MODELS_FILES:$SUNSTONE_LOCATION /models
SUNSTONE_MODELS_JSON_FILES:$SUNSTONE_LOCATION /models/OpenNebulaJSON
SUNSTONE_TEMPLATE_FILES:$SUNSTONE_LOCATION /templates
SUNSTONE_PUBLIC_JS_FILES:$SUNSTONE_LOCATION /public/js
SUNSTONE_PUBLIC_JS_VENDOR_FILES:$SUNSTONE_LOCATION /public/js/vendor
SUNSTONE_PUBLIC_CSS_FILES:$SUNSTONE_LOCATION /public/css
SUNSTONE_PUBLIC_CSS_VENDOR_FILES:$SUNSTONE_LOCATION /public/css/vendor
SUNSTONE_PUBLIC_IMAGES_FILES:$SUNSTONE_LOCATION /public/images
)
2011-02-10 20:16:18 +03:00
INSTALL_ETC_FILES = (
ETC_FILES:$ETC_LOCATION
VMM_EC2_ETC_FILES:$ETC_LOCATION /vmm_ec2
VMM_SSH_ETC_FILES:$ETC_LOCATION /vmm_ssh
VMM_SH_ETC_FILES:$ETC_LOCATION /vmm_sh
IM_EC2_ETC_FILES:$ETC_LOCATION /im_ec2
TM_NFS_ETC_FILES:$ETC_LOCATION /tm_nfs
TM_SSH_ETC_FILES:$ETC_LOCATION /tm_ssh
TM_DUMMY_ETC_FILES:$ETC_LOCATION /tm_dummy
TM_LVM_ETC_FILES:$ETC_LOCATION /tm_lvm
HM_ETC_FILES:$ETC_LOCATION /hm
AUTH_ETC_FILES:$ETC_LOCATION /auth
ECO_ETC_FILES:$ETC_LOCATION
ECO_ETC_TEMPLATE_FILES:$ETC_LOCATION /ec2query_templates
OCCI_ETC_FILES:$ETC_LOCATION
OCCI_ETC_TEMPLATE_FILES:$ETC_LOCATION /occi_templates
)
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Binary files, to be installed under $BIN_LOCATION
#-------------------------------------------------------------------------------
BIN_FILES = " src/nebula/oned \
2010-05-14 19:49:23 +04:00
src/scheduler/src/sched/mm_sched \
2010-05-17 17:54:46 +04:00
src/cli/onevm \
src/cli/onehost \
src/cli/onevnet \
src/cli/oneuser \
2010-06-25 15:39:43 +04:00
src/cli/oneimage \
2010-07-09 13:49:19 +04:00
src/cli/onecluster \
2010-07-22 23:51:59 +04:00
share/scripts/one \
src/authm_mad/oneauth"
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# C/C++ OpenNebula API Library & Development files
# Include files, to be installed under $INCLUDE_LOCATION
# Library files, to be installed under $LIB_LOCATION
#-------------------------------------------------------------------------------
2010-05-17 17:54:46 +04:00
INCLUDE_FILES = ""
LIB_FILES = ""
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Ruby library files, to be installed under $LIB_LOCATION/ruby
#-------------------------------------------------------------------------------
2010-09-01 01:28:05 +04:00
RUBY_LIB_FILES = " src/mad/ruby/ActionManager.rb \
2009-02-10 20:37:38 +03:00
src/mad/ruby/CommandManager.rb \
src/mad/ruby/OpenNebulaDriver.rb \
src/mad/ruby/VirtualMachineDriver.rb \
2011-02-10 21:29:35 +03:00
src/mad/ruby/Ganglia.rb \
2010-05-17 17:54:46 +04:00
src/cli/client_utilities.rb \
src/cli/command_parse.rb \
2009-07-23 17:54:48 +04:00
src/oca/ruby/OpenNebula.rb \
2010-07-09 20:59:42 +04:00
src/tm_mad/TMScript.rb \
src/authm_mad/one_usage.rb \
src/authm_mad/quota.rb \
2010-07-12 21:49:46 +04:00
src/authm_mad/simple_auth.rb \
2010-07-16 20:48:20 +04:00
src/authm_mad/simple_permissions.rb \
src/authm_mad/ssh_auth.rb"
2009-01-02 17:58:51 +03:00
2009-07-23 17:54:48 +04:00
RUBY_OPENNEBULA_LIB_FILES = " src/oca/ruby/OpenNebula/Host.rb \
src/oca/ruby/OpenNebula/HostPool.rb \
src/oca/ruby/OpenNebula/Pool.rb \
src/oca/ruby/OpenNebula/User.rb \
src/oca/ruby/OpenNebula/UserPool.rb \
src/oca/ruby/OpenNebula/VirtualMachine.rb \
src/oca/ruby/OpenNebula/VirtualMachinePool.rb \
src/oca/ruby/OpenNebula/VirtualNetwork.rb \
src/oca/ruby/OpenNebula/VirtualNetworkPool.rb \
2010-06-25 15:36:42 +04:00
src/oca/ruby/OpenNebula/Image.rb \
src/oca/ruby/OpenNebula/ImagePool.rb \
2010-08-01 20:28:03 +04:00
src/oca/ruby/OpenNebula/ImageRepository.rb \
2010-07-09 13:49:19 +04:00
src/oca/ruby/OpenNebula/Cluster.rb \
src/oca/ruby/OpenNebula/ClusterPool.rb \
2009-07-23 17:54:48 +04:00
src/oca/ruby/OpenNebula/XMLUtils.rb"
2010-08-24 18:44:42 +04:00
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Driver executable files, to be installed under $LIB_LOCATION/mads
#-------------------------------------------------------------------------------
2009-09-25 20:03:03 +04:00
MADS_LIB_FILES = " src/mad/sh/madcommon.sh \
2009-01-02 17:58:51 +03:00
src/tm_mad/tm_common.sh \
2010-09-29 14:07:20 +04:00
src/vmm_mad/ssh/one_vmm_ssh.rb \
src/vmm_mad/ssh/one_vmm_ssh \
2010-09-30 19:16:31 +04:00
src/vmm_mad/sh/one_vmm_sh.rb \
src/vmm_mad/sh/one_vmm_sh \
2009-01-02 17:58:51 +03:00
src/vmm_mad/ec2/one_vmm_ec2.rb \
src/vmm_mad/ec2/one_vmm_ec2 \
2010-09-01 21:58:01 +04:00
src/vmm_mad/dummy/one_vmm_dummy.rb \
src/vmm_mad/dummy/one_vmm_dummy \
2009-01-02 17:58:51 +03:00
src/im_mad/im_ssh/one_im_ssh.rb \
src/im_mad/im_ssh/one_im_ssh \
2010-09-30 19:16:31 +04:00
src/im_mad/im_sh/one_im_sh.rb \
src/im_mad/im_sh/one_im_sh \
2009-01-02 17:58:51 +03:00
src/im_mad/ec2/one_im_ec2.rb \
src/im_mad/ec2/one_im_ec2 \
2010-09-01 21:58:01 +04:00
src/im_mad/dummy/one_im_dummy.rb \
src/im_mad/dummy/one_im_dummy \
2009-01-02 17:58:51 +03:00
src/tm_mad/one_tm \
2009-04-04 03:34:33 +04:00
src/tm_mad/one_tm.rb \
src/hm_mad/one_hm.rb \
2010-07-09 20:59:42 +04:00
src/hm_mad/one_hm \
src/authm_mad/one_auth_mad.rb \
2010-07-12 19:07:56 +04:00
src/authm_mad/one_auth_mad"
2010-08-24 18:44:42 +04:00
#-------------------------------------------------------------------------------
# VMM SH Driver KVM scripts, to be installed under $REMOTES_LOCATION/vmm/kvm
#-------------------------------------------------------------------------------
2010-09-29 14:07:20 +04:00
VMM_SSH_KVM_SCRIPTS = " src/vmm_mad/remotes/kvm/cancel \
2010-08-30 15:00:11 +04:00
src/vmm_mad/remotes/kvm/deploy \
src/vmm_mad/remotes/kvm/kvmrc \
src/vmm_mad/remotes/kvm/migrate \
src/vmm_mad/remotes/kvm/restore \
src/vmm_mad/remotes/kvm/save \
src/vmm_mad/remotes/kvm/shutdown"
2010-08-24 18:44:42 +04:00
#-------------------------------------------------------------------------------
# VMM SH Driver Xen scripts, to be installed under $REMOTES_LOCATION/vmm/xen
#-------------------------------------------------------------------------------
2010-09-29 14:07:20 +04:00
VMM_SSH_XEN_SCRIPTS = " src/vmm_mad/remotes/xen/cancel \
2010-08-30 15:00:11 +04:00
src/vmm_mad/remotes/xen/deploy \
src/vmm_mad/remotes/xen/xenrc \
src/vmm_mad/remotes/xen/migrate \
src/vmm_mad/remotes/xen/restore \
src/vmm_mad/remotes/xen/save \
src/vmm_mad/remotes/xen/shutdown"
2010-08-24 18:44:42 +04:00
2011-02-10 21:29:35 +03:00
#-----------------------------------------------------------------------------
# VMM SH Driver xen/kvm scripts, to be installed under $REMOTES_LOCATION/vmm/*
#-----------------------------------------------------------------------------
VMM_SSH_XEN_KVM_POLL = "src/vmm_mad/remotes/poll_xen_kvm.rb"
VMM_SSH_GANGLIA_POLL = "src/vmm_mad/remotes/poll_ganglia.rb"
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
2010-08-19 20:58:00 +04:00
# Information Manager Probes, to be installed under $LIB_LOCATION/remotes
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
2010-08-30 15:00:11 +04:00
IM_PROBES_FILES = "src/im_mad/remotes/run_probes"
2010-08-19 20:58:00 +04:00
2010-10-05 18:09:34 +04:00
IM_PROBES_XEN_FILES = " src/im_mad/remotes/xen.d/xen.rb \
src/im_mad/remotes/xen.d/architecture.sh \
src/im_mad/remotes/xen.d/cpu.sh \
src/im_mad/remotes/xen.d/name.sh"
2010-08-19 20:58:00 +04:00
2010-10-05 18:09:34 +04:00
IM_PROBES_KVM_FILES = " src/im_mad/remotes/kvm.d/kvm.rb \
src/im_mad/remotes/kvm.d/architecture.sh \
src/im_mad/remotes/kvm.d/cpu.sh \
src/im_mad/remotes/kvm.d/name.sh"
2010-08-19 20:58:00 +04:00
2011-02-10 21:29:35 +03:00
IM_PROBES_GANGLIA_FILES = "src/im_mad/remotes/ganglia.d/ganglia_probe"
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Transfer Manager commands, to be installed under $LIB_LOCATION/tm_commands
# - NFS TM, $LIB_LOCATION/tm_commands/nfs
# - SSH TM, $LIB_LOCATION/tm_commands/ssh
# - dummy TM, $LIB_LOCATION/tm_commands/dummy
2009-10-16 17:50:56 +04:00
# - LVM TM, $LIB_LOCATION/tm_commands/lvm
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
NFS_TM_COMMANDS_LIB_FILES = " src/tm_mad/nfs/tm_clone.sh \
src/tm_mad/nfs/tm_delete.sh \
src/tm_mad/nfs/tm_ln.sh \
src/tm_mad/nfs/tm_mkswap.sh \
src/tm_mad/nfs/tm_mkimage.sh \
2009-03-18 01:39:06 +03:00
src/tm_mad/nfs/tm_mv.sh \
src/tm_mad/nfs/tm_context.sh"
2009-01-02 17:58:51 +03:00
SSH_TM_COMMANDS_LIB_FILES = " src/tm_mad/ssh/tm_clone.sh \
src/tm_mad/ssh/tm_delete.sh \
src/tm_mad/ssh/tm_ln.sh \
src/tm_mad/ssh/tm_mkswap.sh \
src/tm_mad/ssh/tm_mkimage.sh \
2009-03-31 14:51:54 +04:00
src/tm_mad/ssh/tm_mv.sh \
src/tm_mad/ssh/tm_context.sh"
2009-01-02 17:58:51 +03:00
DUMMY_TM_COMMANDS_LIB_FILES = "src/tm_mad/dummy/tm_dummy.sh"
2009-10-16 17:50:56 +04:00
LVM_TM_COMMANDS_LIB_FILES = " src/tm_mad/lvm/tm_clone.sh \
src/tm_mad/lvm/tm_delete.sh \
src/tm_mad/lvm/tm_ln.sh \
src/tm_mad/lvm/tm_mkswap.sh \
src/tm_mad/lvm/tm_mkimage.sh \
src/tm_mad/lvm/tm_mv.sh \
src/tm_mad/lvm/tm_context.sh"
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Configuration files for OpenNebula, to be installed under $ETC_LOCATION
#-------------------------------------------------------------------------------
ETC_FILES = " share/etc/oned.conf \
share/etc/defaultrc"
#-------------------------------------------------------------------------------
# Virtualization drivers config. files, to be installed under $ETC_LOCATION
# - ec2, $ETC_LOCATION/vmm_ec2
2010-09-30 19:16:31 +04:00
# - sh, $ETC_LOCATION/vmm_sh
2010-09-29 14:07:20 +04:00
# - ssh, $ETC_LOCATION/vmm_ssh
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
VMM_EC2_ETC_FILES = " src/vmm_mad/ec2/vmm_ec2rc \
src/vmm_mad/ec2/vmm_ec2.conf"
2010-09-29 14:07:20 +04:00
VMM_SSH_ETC_FILES = " src/vmm_mad/ssh/vmm_sshrc \
src/vmm_mad/ssh/vmm_ssh_kvm.conf \
src/vmm_mad/ssh/vmm_ssh_xen.conf"
2011-02-10 21:29:35 +03:00
2010-09-30 19:16:31 +04:00
VMM_SH_ETC_FILES = "src/vmm_mad/sh/vmm_shrc"
2010-08-24 18:44:42 +04:00
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Information drivers config. files, to be installed under $ETC_LOCATION
# - ec2, $ETC_LOCATION/im_ec2
#-------------------------------------------------------------------------------
IM_EC2_ETC_FILES = " src/im_mad/ec2/im_ec2rc \
src/im_mad/ec2/im_ec2.conf"
#-------------------------------------------------------------------------------
# Storage drivers config. files, to be installed under $ETC_LOCATION
# - nfs, $ETC_LOCATION/tm_nfs
# - ssh, $ETC_LOCATION/tm_ssh
# - dummy, $ETC_LOCATION/tm_dummy
2009-10-16 17:50:56 +04:00
# - lvm, $ETC_LOCATION/tm_lvm
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
TM_NFS_ETC_FILES = " src/tm_mad/nfs/tm_nfs.conf \
src/tm_mad/nfs/tm_nfsrc"
TM_SSH_ETC_FILES = " src/tm_mad/ssh/tm_ssh.conf \
src/tm_mad/ssh/tm_sshrc"
TM_DUMMY_ETC_FILES = " src/tm_mad/dummy/tm_dummy.conf \
src/tm_mad/dummy/tm_dummyrc"
2009-10-16 17:50:56 +04:00
TM_LVM_ETC_FILES = " src/tm_mad/lvm/tm_lvm.conf \
src/tm_mad/lvm/tm_lvmrc"
2009-04-04 03:34:33 +04:00
#-------------------------------------------------------------------------------
# Hook Manager driver config. files, to be installed under $ETC_LOCATION/hm
#-------------------------------------------------------------------------------
HM_ETC_FILES = "src/hm_mad/hmrc"
2010-07-09 20:59:42 +04:00
#-------------------------------------------------------------------------------
# Hook Manager driver config. files, to be installed under $ETC_LOCATION/hm
#-------------------------------------------------------------------------------
2010-07-13 20:17:25 +04:00
AUTH_ETC_FILES = " src/authm_mad/auth_mad \
src/authm_mad/auth.conf"
2010-07-09 20:59:42 +04:00
2009-01-02 17:58:51 +03:00
#-------------------------------------------------------------------------------
# Sample files, to be installed under $SHARE_LOCATION/examples
#-------------------------------------------------------------------------------
EXAMPLE_SHARE_FILES = " share/examples/vm.template \
share/examples/vm.schema \
share/examples/private.net \
share/examples/public.net"
#-------------------------------------------------------------------------------
# TM Sample files, to be installed under $SHARE_LOCATION/examples/tm
#-------------------------------------------------------------------------------
TM_EXAMPLE_SHARE_FILES = " share/examples/tm/tm_clone.sh \
share/examples/tm/tm_delete.sh \
share/examples/tm/tm_ln.sh \
share/examples/tm/tm_mkimage.sh \
share/examples/tm/tm_mkswap.sh \
share/examples/tm/tm_mv.sh"
2009-07-21 14:45:54 +04:00
#-------------------------------------------------------------------------------
# HOOK scripts, to be installed under $SHARE_LOCATION/hooks
#-------------------------------------------------------------------------------
2009-10-23 18:52:03 +04:00
HOOK_SHARE_FILES = " share/hooks/ebtables-xen \
share/hooks/ebtables-kvm \
2010-07-22 20:20:12 +04:00
share/hooks/ebtables-flush \
2011-01-17 17:27:10 +03:00
share/hooks/host_error.rb \
2010-07-22 20:20:12 +04:00
share/hooks/image.rb"
2009-07-21 14:45:54 +04:00
2009-07-21 18:56:35 +04:00
#-------------------------------------------------------------------------------
2009-10-12 03:06:46 +04:00
# Common Cloud Files
2009-07-21 18:56:35 +04:00
#-------------------------------------------------------------------------------
2009-10-12 03:06:46 +04:00
COMMON_CLOUD_LIB_FILES = " src/cloud/common/CloudServer.rb \
2009-10-21 21:00:59 +04:00
src/cloud/common/CloudClient.rb \
2010-07-17 05:48:07 +04:00
src/cloud/common/Configuration.rb"
2009-07-23 16:01:47 +04:00
2009-10-22 15:20:27 +04:00
COMMON_CLOUD_CLIENT_LIB_FILES = "src/cloud/common/CloudClient.rb"
2009-10-12 03:06:46 +04:00
#-------------------------------------------------------------------------------
2010-07-11 22:39:10 +04:00
# EC2 Query for OpenNebula
2009-10-12 03:06:46 +04:00
#-------------------------------------------------------------------------------
ECO_LIB_FILES = " src/cloud/ec2/lib/EC2QueryClient.rb \
src/cloud/ec2/lib/EC2QueryServer.rb \
2010-07-16 21:12:25 +04:00
src/cloud/ec2/lib/ImageEC2.rb \
2009-10-12 03:06:46 +04:00
src/cloud/ec2/lib/econe-server.rb"
2009-10-22 15:20:27 +04:00
ECO_LIB_CLIENT_FILES = "src/cloud/ec2/lib/EC2QueryClient.rb"
2009-10-12 03:06:46 +04:00
ECO_LIB_VIEW_FILES = " src/cloud/ec2/lib/views/describe_images.erb \
src/cloud/ec2/lib/views/describe_instances.erb \
src/cloud/ec2/lib/views/register_image.erb \
src/cloud/ec2/lib/views/run_instances.erb \
src/cloud/ec2/lib/views/terminate_instances.erb"
2009-07-21 18:56:35 +04:00
2009-10-12 03:06:46 +04:00
ECO_BIN_FILES = " src/cloud/ec2/bin/econe-server \
src/cloud/ec2/bin/econe-describe-images \
src/cloud/ec2/bin/econe-describe-instances \
src/cloud/ec2/bin/econe-register \
src/cloud/ec2/bin/econe-run-instances \
src/cloud/ec2/bin/econe-terminate-instances \
src/cloud/ec2/bin/econe-upload"
2009-07-21 18:56:35 +04:00
2009-10-22 15:20:27 +04:00
ECO_BIN_CLIENT_FILES = " src/cloud/ec2/bin/econe-describe-images \
src/cloud/ec2/bin/econe-describe-instances \
src/cloud/ec2/bin/econe-register \
src/cloud/ec2/bin/econe-run-instances \
src/cloud/ec2/bin/econe-terminate-instances \
src/cloud/ec2/bin/econe-upload"
2009-10-12 03:06:46 +04:00
ECO_ETC_FILES = "src/cloud/ec2/etc/econe.conf"
ECO_ETC_TEMPLATE_FILES = "src/cloud/ec2/etc/templates/m1.small.erb"
2009-07-21 18:56:35 +04:00
2009-10-19 21:35:50 +04:00
#-----------------------------------------------------------------------------
2009-09-03 22:10:55 +04:00
# OCCI files
2009-10-19 21:35:50 +04:00
#-----------------------------------------------------------------------------
2009-09-03 22:10:55 +04:00
2009-10-20 06:01:57 +04:00
OCCI_LIB_FILES = " src/cloud/occi/lib/OCCIServer.rb \
2009-10-19 21:35:50 +04:00
src/cloud/occi/lib/occi-server.rb \
src/cloud/occi/lib/OCCIClient.rb \
2009-09-03 22:10:55 +04:00
src/cloud/occi/lib/VirtualMachineOCCI.rb \
src/cloud/occi/lib/VirtualMachinePoolOCCI.rb \
src/cloud/occi/lib/VirtualNetworkOCCI.rb \
2009-10-15 21:37:25 +04:00
src/cloud/occi/lib/VirtualNetworkPoolOCCI.rb \
src/cloud/occi/lib/ImageOCCI.rb \
2010-07-11 22:39:10 +04:00
src/cloud/occi/lib/ImagePoolOCCI.rb"
2009-09-03 22:10:55 +04:00
2009-10-22 15:20:27 +04:00
OCCI_LIB_CLIENT_FILES = "src/cloud/occi/lib/OCCIClient.rb"
2009-10-12 03:06:46 +04:00
OCCI_BIN_FILES = " src/cloud/occi/bin/occi-server \
src/cloud/occi/bin/occi-compute \
src/cloud/occi/bin/occi-network \
src/cloud/occi/bin/occi-storage"
2009-09-03 22:10:55 +04:00
2009-10-22 15:20:27 +04:00
OCCI_BIN_CLIENT_FILES = " src/cloud/occi/bin/occi-compute \
src/cloud/occi/bin/occi-network \
src/cloud/occi/bin/occi-storage"
2009-10-12 03:06:46 +04:00
OCCI_ETC_FILES = "src/cloud/occi/etc/occi-server.conf"
2009-09-03 22:10:55 +04:00
2010-11-30 14:52:30 +03:00
OCCI_ETC_TEMPLATE_FILES = " src/cloud/occi/etc/templates/common.erb \
2010-12-02 21:19:01 +03:00
src/cloud/occi/etc/templates/custom.erb \
2010-11-30 14:52:30 +03:00
src/cloud/occi/etc/templates/small.erb \
2009-10-12 03:06:46 +04:00
src/cloud/occi/etc/templates/medium.erb \
src/cloud/occi/etc/templates/large.erb"
2009-07-21 18:56:35 +04:00
2011-02-10 17:57:11 +03:00
#-----------------------------------------------------------------------------
# CLI files
#-----------------------------------------------------------------------------
CLI_LIB_FILES = " src/mad/ruby/CommandManager.rb \
src/cli/client_utilities.rb \
src/cli/command_parse.rb \
src/oca/ruby/OpenNebula.rb"
CLI_BIN_FILES = " src/cli/onevm \
src/cli/onehost \
src/cli/onevnet \
src/cli/oneuser \
src/cli/oneimage \
src/cli/onecluster"
2011-02-23 19:27:17 +03:00
#-----------------------------------------------------------------------------
# Sunstone files
#-----------------------------------------------------------------------------
SUNSTONE_FILES = " src/sunstone/config.ru \
src/sunstone/sunstone-server.rb"
SUNSTONE_BIN_FILES = "src/sunstone/bin/sunstone-server"
SUNSTONE_MODELS_FILES = " src/sunstone/models/OpenNebulaJSON.rb \
src/sunstone/models/SunstoneServer.rb"
SUNSTONE_MODELS_JSON_FILES = " src/sunstone/models/OpenNebulaJSON/ClusterJSON.rb \
src/sunstone/models/OpenNebulaJSON/HostJSON.rb \
src/sunstone/models/OpenNebulaJSON/ImageJSON.rb \
src/sunstone/models/OpenNebulaJSON/JSONUtils.rb \
src/sunstone/models/OpenNebulaJSON/PoolJSON.rb \
src/sunstone/models/OpenNebulaJSON/UserJSON.rb \
src/sunstone/models/OpenNebulaJSON/VirtualMachineJSON.rb \
src/sunstone/models/OpenNebulaJSON/VirtualNetworkJSON.rb"
SUNSTONE_TEMPLATE_FILES = " src/sunstone/templates/index.html \
src/sunstone/templates/login.html"
SUNSTONE_PUBLIC_JS_FILES = " src/sunstone/public/js/layout.js \
src/sunstone/public/js/login.js \
src/sunstone/public/js/one-ui_views.js \
src/sunstone/public/js/one-ui_views.templates.js \
src/sunstone/public/js/opennebula.js"
SUNSTONE_PUBLIC_JS_VENDOR_FILES = " src/sunstone/public/js/vendor/base64.js \
src/sunstone/public/js/vendor/jquery-1.4.4.min.js \
src/sunstone/public/js/vendor/jquery.dataTables.min.js \
src/sunstone/public/js/vendor/jquery.jgrowl_minimized.js \
src/sunstone/public/js/vendor/jquery.layout.min-1.2.0.js \
src/sunstone/public/js/vendor/jquery-ui-1.8.7.custom.min.js"
SUNSTONE_PUBLIC_CSS_FILES = " src/sunstone/public/css/application.css \
src/sunstone/public/css/demo_table_jui.css \
src/sunstone/public/css/jquery.jgrowl.css \
src/sunstone/public/css/layout.css \
src/sunstone/public/css/layout-default-latest.css \
src/sunstone/public/css/login.css"
SUNSTONE_PUBLIC_CSS_VENDOR_FILES = " \
src/sunstone/public/css/vendor/jquery-ui-1.8.7.custom.css \
src/sunstone/public/css/vendor/ui-bg_flat_0_575c5b_40x100.png \
src/sunstone/public/css/vendor/ui-bg_flat_0_8f9392_40x100.png \
src/sunstone/public/css/vendor/ui-bg_flat_0_aaaaaa_40x100.png \
src/sunstone/public/css/vendor/ui-bg_flat_75_ffffff_40x100.png \
src/sunstone/public/css/vendor/ui-bg_glass_55_fbf9ee_1x400.png \
src/sunstone/public/css/vendor/ui-bg_glass_65_ffffff_1x400.png \
src/sunstone/public/css/vendor/ui-bg_glass_75_dadada_1x400.png \
src/sunstone/public/css/vendor/ui-bg_glass_75_e6e6e6_1x400.png \
src/sunstone/public/css/vendor/ui-bg_glass_95_fef1ec_1x400.png \
src/sunstone/public/css/vendor/ui-bg_highlight-soft_75_cccccc_1x100.png \
src/sunstone/public/css/vendor/ui-icons_222222_256x240.png \
src/sunstone/public/css/vendor/ui-icons_2e83ff_256x240.png \
src/sunstone/public/css/vendor/ui-icons_454545_256x240.png \
src/sunstone/public/css/vendor/ui-icons_888888_256x240.png \
src/sunstone/public/css/vendor/ui-icons_cd0a0a_256x240.png"
SUNSTONE_PUBLIC_IMAGES_FILES = " src/sunstone/public/images/ajax-loader.gif \
src/sunstone/public/images/login_over.png \
src/sunstone/public/images/login.png \
src/sunstone/public/images/opennebula-sunstone-big.png \
src/sunstone/public/images/opennebula-sunstone-small.png \
src/sunstone/public/images/panel.png \
src/sunstone/public/images/pbar.gif \
src/sunstone/public/images/Refresh-icon.png"
SUNSTONE_RUBY_LIB_FILES = " src/mad/ruby/CommandManager.rb \
src/oca/ruby/OpenNebula.rb"
2010-10-14 19:24:01 +04:00
#-----------------------------------------------------------------------------
# MAN files
#-----------------------------------------------------------------------------
MAN_FILES = " share/man/oneauth.8.gz \
share/man/onecluster.8.gz \
share/man/onehost.8.gz \
share/man/oneimage.8.gz \
share/man/oneuser.8.gz \
share/man/onevm.8.gz \
2010-10-19 19:28:36 +04:00
share/man/onevnet.8.gz \
share/man/econe-describe-images.8.gz \
share/man/econe-describe-instances.8.gz \
share/man/econe-register.8.gz \
share/man/econe-run-instances.8.gz \
share/man/econe-terminate-instances.8.gz \
share/man/econe-upload.8.gz \
share/man/occi-compute.8.gz \
share/man/occi-network.8.gz \
share/man/occi-storage.8.gz"
2010-10-14 19:24:01 +04:00
2009-10-19 21:35:50 +04:00
#-----------------------------------------------------------------------------
#-----------------------------------------------------------------------------
2009-01-02 17:58:51 +03:00
# INSTALL.SH SCRIPT
2009-10-19 21:35:50 +04:00
#-----------------------------------------------------------------------------
#-----------------------------------------------------------------------------
2009-01-02 17:58:51 +03:00
# --- Create OpenNebula directories ---
2010-07-11 22:39:10 +04:00
if [ " $UNINSTALL " = "no" ] ; then
2009-01-02 17:58:51 +03:00
for d in $MAKE_DIRS ; do
2009-01-19 19:40:46 +03:00
mkdir -p $DESTDIR $d
2009-01-02 17:58:51 +03:00
done
fi
2008-11-13 19:21:17 +03:00
2009-01-02 17:58:51 +03:00
# --- Install/Uninstall files ---
2008-12-02 18:52:03 +03:00
2009-01-02 17:58:51 +03:00
do_file( ) {
if [ " $UNINSTALL " = "yes" ] ; then
rm $2 /` basename $1 `
else
2009-08-27 21:25:39 +04:00
if [ " $LINK " = "yes" ] ; then
ln -s $SRC_DIR /$1 $DESTDIR $2
else
cp $SRC_DIR /$1 $DESTDIR $2
fi
2009-01-02 17:58:51 +03:00
fi
}
2008-12-02 18:52:03 +03:00
2009-09-25 22:18:50 +04:00
2011-02-23 19:27:17 +03:00
if [ " $CLIENT " = "yes" ] ; then
2011-02-10 17:57:11 +03:00
INSTALL_SET = ${ INSTALL_CLIENT_FILES [@] }
2011-02-23 19:27:17 +03:00
elif [ " $SUNSTONE " = "yes" ] ; then
2011-02-24 14:28:57 +03:00
INSTALL_SET = " ${ INSTALL_SUNSTONE_RUBY_FILES [@] } ${ INSTALL_SUNSTONE_FILES [@] } "
2011-02-23 19:27:17 +03:00
else
INSTALL_SET = " ${ INSTALL_FILES [@] } ${ INSTALL_SUNSTONE_FILES [@] } "
2009-09-25 22:18:50 +04:00
fi
for i in ${ INSTALL_SET [@] } ; do
2009-01-02 17:58:51 +03:00
SRC = $` echo $i | cut -d: -f1`
DST = ` echo $i | cut -d: -f2`
2010-07-11 22:39:10 +04:00
eval SRC_FILES = $SRC
for f in $SRC_FILES ; do
2009-01-02 17:58:51 +03:00
do_file $f $DST
done
done
2008-11-13 19:21:17 +03:00
2011-02-23 19:27:17 +03:00
if [ " $INSTALL_ETC " = "yes" ] ; then
2009-01-02 17:58:51 +03:00
for i in ${ INSTALL_ETC_FILES [@] } ; do
SRC = $` echo $i | cut -d: -f1`
DST = ` echo $i | cut -d: -f2`
2010-07-11 22:39:10 +04:00
2009-08-27 21:25:39 +04:00
eval SRC_FILES = $SRC
2010-07-11 22:39:10 +04:00
2009-08-27 21:25:39 +04:00
OLD_LINK = $LINK
LINK = "no"
2010-07-11 22:39:10 +04:00
for f in $SRC_FILES ; do
2009-01-02 17:58:51 +03:00
do_file $f $DST
done
2010-07-11 22:39:10 +04:00
2009-08-27 21:25:39 +04:00
LINK = $OLD_LINK
2009-01-02 17:58:51 +03:00
done
fi
2008-06-17 20:27:32 +04:00
2009-01-02 17:58:51 +03:00
# --- Set ownership or remove OpenNebula directories ---
2008-12-02 19:16:20 +03:00
2010-07-11 22:39:10 +04:00
if [ " $UNINSTALL " = "no" ] ; then
2009-01-19 19:40:46 +03:00
for d in $CHOWN_DIRS ; do
2009-10-21 19:48:46 +04:00
chown -R $ONEADMIN_USER :$ONEADMIN_GROUP $DESTDIR $d
2009-01-19 19:40:46 +03:00
done
2010-07-27 17:51:05 +04:00
# --- Set correct permissions for Image Repository ---
2010-10-06 13:56:02 +04:00
if [ -d " $DESTDIR $IMAGES_LOCATION " ] ; then
chmod 3770 $DESTDIR $IMAGES_LOCATION
2010-07-27 17:51:05 +04:00
fi
2009-01-02 17:58:51 +03:00
else
2009-05-07 19:23:13 +04:00
for d in ` echo $DELETE_DIRS | awk '{for (i=NF;i>=1;i--) printf $i" "}' ` ; do
2009-01-02 17:58:51 +03:00
rmdir $d
done
fi