From b92cda90b04f2c378774d5e9bd6f1b251715bfdf Mon Sep 17 00:00:00 2001 From: ronivay Date: Fri, 1 Sep 2017 20:16:50 +0300 Subject: [PATCH] Update readme and script to offer XO install without installing dependencies --- README.md | 25 ++++++++++++++++++++----- xo-install.sh | 13 ++++++------- 2 files changed, 26 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index d9651eb..7442f24 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,22 @@ Clone this repository and run xo-install.sh script as root ./install-xo.sh ``` -Tool makes some checks and offers options to update/install Xen-Orchestra or deploy a container. +Tool makes some checks and offers options: + +1. Autoinstall + - Installs all dependencies (necessary packages and Xen-Orchestra itself) + - Packages listed in the end of this README + +2. Update / Install without dependencies + - Installs Xen-Orchestra from latest sources (doesn't install any packages) + +3. Deploy container + - Offers options to build container locally or pull from dockerhub + +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 ### 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. @@ -54,8 +69,8 @@ Below is a list of packages that will be installed if missing. CentOS: - curl - epel-release -- nodejs -- npm +- nodejs (v6) +- npm (v3) - yarn - gcc - gcc+ @@ -71,8 +86,8 @@ Debian/Ubuntu: - ca-certificates - curl - yarn -- nodejs -- npm +- nodejs (v6) +- npm (v3) - build-essential - redis-server - libpng-dev diff --git a/xo-install.sh b/xo-install.sh index cf8a13e..3e7713c 100755 --- a/xo-install.sh +++ b/xo-install.sh @@ -134,7 +134,7 @@ function InstallXO { if [ $XOUSER ]; then if [[ -z $(getent passwd $XOUSER) ]]; then echo - echo "Creating $XOUSER user" + echo "Creating missing $XOUSER user" useradd -s /sbin/nologin $XOUSER echo sleep 2 @@ -318,11 +318,10 @@ echo echo "- By default xo-server will be running as root to prevent issues with permissions and port binding." echo " uncomment and edit XOUSER variable in this script to add this custom user to XO-config" echo " (Notice that you might have to make other changes depending on your system for this to work)" -echo " This method only changes the user which runs the service. Other install tasks like node packages are still installed as root" +echo " This method only changes the user which runs the service. Other install tasks like node packages are still ran as root" echo -echo "- Updating will result in a completely fresh source compile and only active symlink will be changed" echo "- Data stored in redis and /var/lib/xo-server/data will not be touched" -echo "- Update option will only work for installations originally done with this tool" +echo "- Option 2. actually creates a new build from sources but works as an update to installations originally done with this tool" echo echo "Following options will be used for installation:" echo @@ -342,9 +341,9 @@ echo "Errorlog is stored to $LOGFILE for debug purposes" echo "-----------------------------------------" echo -echo "1. Install" -echo "2. Update" -echo "3. Run with docker" +echo "1. Autoinstall" +echo "2. Update / Install without packages" +echo "3. Deploy docker container" echo "4. Exit" echo read -p ": " option