From a912401c27644852c80a9ec782150ee49e2320bd Mon Sep 17 00:00:00 2001 From: ronivay Date: Thu, 26 Jul 2018 17:52:42 +0300 Subject: [PATCH] Minor fixes and added travis configuration file --- .gitignore | 1 + .travis.yml | 5 +++++ tests/README.md | 2 +- xo-install.sh | 12 ++++++++++++ 4 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 .travis.yml diff --git a/.gitignore b/.gitignore index 7b0685d..cb81e89 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ tests/* !tests/Debian !tests/Debian/Vagrantfile !tests/run-tests.sh +!tests/README.md diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..76054f5 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,5 @@ +sudo: require +language: bash + +script: + - ./xo-install.sh --run-test diff --git a/tests/README.md b/tests/README.md index 5a22c84..a5ffdff 100644 --- a/tests/README.md +++ b/tests/README.md @@ -20,7 +20,7 @@ Ubuntu HTTP Check: success Requirements: ``` -OSX +OSX (not tested with anything else since this is mainly for my own use) Vagrant Virtualbox ```` diff --git a/xo-install.sh b/xo-install.sh index ab3acbd..ad80b28 100755 --- a/xo-install.sh +++ b/xo-install.sh @@ -317,6 +317,7 @@ function InstallXO { else echo echo "Looks like there was a problem when starting xo-server/reading journalctl. Please see logs for more details" + exit 1; fi } 2>$LOGFILE @@ -345,6 +346,17 @@ function UpdateXOAutomate { UpdateNodeYarn UpdateXO ;; + --run-test) + if [ $OSNAME == "CentOS" ]; then + InstallDependenciesCentOS + InstallXO + exit 0 + else + InstallDependenciesDebian + InstallXO + exit 0 + fi + ;; *) StartUpScreen ;;