From 0e4c5397398687452af623bc4ae6692cdbe0fd08 Mon Sep 17 00:00:00 2001 From: Developpeur Egare Date: Sat, 30 May 2015 09:24:35 +0200 Subject: [PATCH] Changes to be committed: modified: scripts/install --- scripts/install | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index 33c9383..fac5df9 100644 --- a/scripts/install +++ b/scripts/install @@ -5,6 +5,8 @@ domain=$1 user=$2 is_public=$3 +versionname=$(lsb_release -a | grep Codename | awk -F' ' '{print $2}') + # Check user parameter sudo yunohost user list --json | grep -q "\"username\": \"$user\"" if [[ ! $? -eq 0 ]]; then @@ -35,7 +37,9 @@ sudo apt-get update sudo apt-get install gawk libyaml-dev libsqlite3-dev sqlite3 autoconf libgdbm-dev libncurses5-dev automake bison libffi-dev\ build-essential libssl-dev libcurl4-openssl-dev libxml2-dev libxslt-dev imagemagick ghostscript git curl libmysqlclient-dev\ libmagickwand-dev nodejs-legacy npm -y -sudo apt-get install -t wheezy-backports redis-server -y + +[ "$versionname" == "wheezy" ] && sudo apt-get install -t wheezy-backports redis-server -y +[ "$versionname" != "wheezy" ] && sudo apt-get install redis-server -y # get source code git clone -b master git://github.com/diaspora/diaspora.git @@ -78,7 +82,9 @@ sudo su - diaspora -c "curl -sSL https://rvm.io/mpapis.asc | gpg --import - ; cu sudo su - diaspora -c "rvm install 2.0" -sudo env REALLY_GEM_UPDATE_SYSTEM=1 gem update --system --no-user-install +#sudo env REALLY_GEM_UPDATE_SYSTEM=1 gem update --system --no-user-install +sudo su - diaspora -c "env REALLY_GEM_UPDATE_SYSTEM=1 gem update --system --no-user-install" +sudo su - diaspora -c "gem install bundler" # construct diaspora app sudo su - diaspora -c "RAILS_ENV=production bundle install --without test development"