From cb019ff194c0a7dc7841cd1c317630cf092d2c64 Mon Sep 17 00:00:00 2001 From: Raul Marin Date: Tue, 22 Oct 2019 18:35:51 +0200 Subject: [PATCH] Install python3 for PG12 run --- .travis.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.travis.yml b/.travis.yml index c7254c6..90a9221 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,11 +10,12 @@ env: - PGPORT=5432 - POSTGIS_VERSION="2.5" - matrix: - - POSTGRESQL_VERSION="9.6" - - POSTGRESQL_VERSION="10" - - POSTGRESQL_VERSION="11" - - POSTGRESQL_VERSION="12" +jobs: + include: + - env: POSTGRESQL_VERSION="9.6" + - env: POSTGRESQL_VERSION="10" + - env: POSTGRESQL_VERSION="11" + - env: POSTGRESQL_VERSION="12" script: - sudo service postgresql stop; @@ -23,10 +24,8 @@ script: - if [[ $POSTGRESQL_VERSION == '9.6' ]]; then sudo apt-get install -y postgresql-contrib-9.6; fi; - sudo apt-get install -y --allow-unauthenticated postgresql-$POSTGRESQL_VERSION-postgis-$POSTGIS_VERSION postgresql-$POSTGRESQL_VERSION-postgis-$POSTGIS_VERSION-scripts postgis # For pre12, install plpython2. For PG12 install plpython3 - - sudo apt-get install python-pip python3-pip - - sudo pip install redis==2.4.9; - - sudo pip3 install redis==2.4.9; - - if [[ $POSTGRESQL_VERSION != '12' ]]; then sudo apt-get install -y postgresql-plpython-$POSTGRESQL_VERSION; else sudo apt-get install -y postgresql-plpython3-12; fi; + - sudo apt-get install -y python python-pip python3 python3-pip + - if [[ $POSTGRESQL_VERSION != '12' ]]; then sudo pip install redis; sudo apt-get install -y postgresql-plpython-$POSTGRESQL_VERSION; else sudo pip3 install pip3; sudo pip3 install setuptools; sudo pip3 install redis; sudo apt-get install -y postgresql-plpython3-12; fi; - sudo pg_dropcluster --stop $POSTGRESQL_VERSION main - sudo rm -rf /etc/postgresql/$POSTGRESQL_VERSION /var/lib/postgresql/$POSTGRESQL_VERSION - sudo pg_createcluster -u postgres $POSTGRESQL_VERSION main -- --auth-local trust --auth-host password