From 25f8bb068c4a2a65a8d681f168b4e9e212194a41 Mon Sep 17 00:00:00 2001 From: Gil Moskowitz Date: Wed, 17 Sep 2014 09:42:02 -0400 Subject: [PATCH] simplify testing with diff postgres version (still need to sync this with vagrant_setup.sh manually) --- scripts/install_xtuple.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/install_xtuple.sh b/scripts/install_xtuple.sh index 72aab6933..b8ae265c8 100644 --- a/scripts/install_xtuple.sh +++ b/scripts/install_xtuple.sh @@ -139,7 +139,10 @@ install_packages() { sudo add-apt-repository -y "deb http://apt.postgresql.org/pub/repos/apt/ ${DEBDIST}-pgdg main" sudo wget -qO- https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - sudo apt-get -qq update 2>&1 | tee -a $LOG_FILE - sudo apt-get -q -y install curl build-essential libssl-dev postgresql-9.1 postgresql-server-dev-9.1 postgresql-contrib-9.1 postgresql-9.1-plv8 2>&1 | tee -a $LOG_FILE + sudo apt-get -q -y install curl build-essential libssl-dev \ + postgresql-${PG_VERSION} postgresql-server-dev-${PG_VERSION} \ + postgresql-contrib-${PG_VERSION} postgresql-${PG_VERSION}-plv8 2>&1 \ + | tee -a $LOG_FILE if [ ! -d "/usr/local/nvm" ]; then sudo rm -f /usr/local/bin/nvm @@ -158,6 +161,7 @@ install_packages() { # npm no longer supports its self-signed certificates log "telling npm to use known registrars..." npm config set ca "" + sudo chown -R $USER $HOME/.npm log "installing npm modules..." npm install --unsafe-perm 2>&1 | tee -a $LOG_FILE @@ -189,7 +193,7 @@ setup_postgres() { return 1 fi - PGDIR=/etc/postgresql/9.1/main + PGDIR=/etc/postgresql/${PG_VERSION}/main log "copying configs..." sudo cp $PGDIR/postgresql.conf $PGDIR/postgresql.conf.default -- 2.39.2