add option to install all available plugins, fix config file paths, fix typo and update README
This commit is contained in:
@@ -7,7 +7,7 @@ This repo consist of script to install and update [Xen Orchestra](https://xen-or
|
||||
|
||||
Installation is done using latest xo-server and xo-web sources. With this method Xen-Orchestra has all features unlocked which are normally available only with monthly fee.
|
||||
|
||||
Optional plugins can be installed. They are included in XO repository, but not installed by default. Check list from [Xen Orchestra plugins](https://github.com/vatesfr/xen-orchestra/tree/master/packages) and edit xo-install.sh accordingly.
|
||||
Optional plugins can be installed. They are included in XO repository, but not installed by default. Check list from [Xen Orchestra plugins](https://github.com/vatesfr/xen-orchestra/tree/master/packages) and edit xo-install.cfg accordingly.
|
||||
|
||||
|
||||
Paid version comes with pro support and appliance and is the suggested option for larger environments. Method that this script offers comes with no support and is not the officially recommended way of using Xen-Orchestra. This is mainly intended for testing purposes and small environments which don't require support.
|
||||
@@ -52,7 +52,7 @@ Tool makes some checks and offers options:
|
||||
notes:
|
||||
|
||||
- If you choose to install with option 2, you need to take care that required packages are already installed
|
||||
- You can change xo-server and xo-web git branch by editing xo-install.sh scripts $BRANCH variable
|
||||
- You can change xo-server and xo-web git branch/tag by editing xo-install.cfg $BRANCH variable
|
||||
|
||||
### docker
|
||||
You can also build the docker image locally if you wish or pull it from [docker hub](https://hub.docker.com/r/ronivay/xen-orchestra/) without using the script.
|
||||
|
@@ -14,8 +14,9 @@ BRANCH="master"
|
||||
# Log path for possible errors
|
||||
LOGFILE="$(dirname $0)/xo-install.log"
|
||||
|
||||
# comma separated list of plugins to be installed, check README for more information
|
||||
# Comma separated list of plugins to be installed, check README for more information. Optionally set to all, to install all plugins
|
||||
#PLUGINS="xo-server-transport-email,xo-server-usage-report,xo-server-perf-alert"
|
||||
#PLUGINS="all"
|
||||
|
||||
# NodeJS and Yarn are automatically updated when running update. Switch this option to false if you want to disable it.
|
||||
AUTOUPDATE="true"
|
||||
|
@@ -6,8 +6,8 @@
|
||||
# Repository: https://github.com/ronivay/XenOrchestraInstallerUpdater #
|
||||
#########################################################################
|
||||
|
||||
SAMPLE_CONFIG_FILE="sample.xo-install.cfg"
|
||||
CONFIG_FILE="xo-install.cfg"
|
||||
SAMPLE_CONFIG_FILE="$(dirname $0)/sample.xo-install.cfg"
|
||||
CONFIG_FILE="$(dirname $0)/xo-install.cfg"
|
||||
|
||||
# Deploy default configuration file if the user doesn't have their own yet.
|
||||
if [[ ! -e "$CONFIG_FILE" ]]; then
|
||||
@@ -201,18 +201,24 @@ function InstallXOPlugins {
|
||||
|
||||
if [[ "$PLUGINS" ]] && [[ ! -z "$PLUGINS" ]]; then
|
||||
|
||||
echo
|
||||
echo "Installing plugins defined in PLUGINS variable"
|
||||
echo
|
||||
local PLUGINSARRAY=($(echo "$PLUGINS" | tr ',' ' '))
|
||||
for x in "${PLUGINSARRAY[@]}"; do
|
||||
if [[ $(find $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages -type d -name "$x") ]]; then
|
||||
ln -sn $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/$x $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/xo-server/node_modules/
|
||||
else
|
||||
echo "No $x plugin found from xen-orchestra packages, skipping"
|
||||
if [[ "$PLUGINS" == "all" ]]; then
|
||||
echo
|
||||
echo "Installing all available plugins as defined in PLUGINS variable"
|
||||
find "$INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/" -maxdepth 1 -mindepth 1 -not -name "xo-server" -not -name "xo-web" -not -name "xo-server-cloud" -exec ln -sn {} "$INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/xo-server/node_modules/" \;
|
||||
else
|
||||
echo
|
||||
echo "Installing plugins defined in PLUGINS variable"
|
||||
echo
|
||||
local PLUGINSARRAY=($(echo "$PLUGINS" | tr ',' ' '))
|
||||
for x in "${PLUGINSARRAY[@]}"; do
|
||||
if [[ $(find $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages -type d -name "$x") ]]; then
|
||||
ln -sn $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/$x $INSTALLDIR/xo-builds/xen-orchestra-$TIME/packages/xo-server/node_modules/
|
||||
else
|
||||
echo "No $x plugin found from xen-orchestra packages, skipping"
|
||||
continue
|
||||
fi
|
||||
done
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
cd $INSTALLDIR/xo-builds/xen-orchestra-$TIME && yarn >/dev/null && yarn build >/dev/null
|
||||
else
|
||||
@@ -434,7 +440,7 @@ function InstallXO {
|
||||
|
||||
timeout 60 bash <<-"EOF"
|
||||
while [[ -z $(journalctl -u xo-server | sed -n 'H; /Starting XO Server/h; ${g;p;}' | grep "https\{0,1\}:\/\/\[::\]:$PORT") ]]; do
|
||||
echo "waiting port to be open"
|
||||
echo "waiting for port to be open"
|
||||
sleep 10
|
||||
done
|
||||
EOF
|
||||
|
Reference in New Issue
Block a user