]> git.ipfire.org Git - thirdparty/patchwork.git/commitdiff
travis: Update postgreSQL 10 steps
authorStephen Finucane <stephen@that.guru>
Sun, 8 Sep 2019 15:31:08 +0000 (16:31 +0100)
committerStephen Finucane <stephen@that.guru>
Sun, 8 Sep 2019 17:27:28 +0000 (18:27 +0100)
This is failing since the update to Xenial [1] with the following
warning:

  $ sudo -u postgres psql -c "grant ALL on DATABASE postgres to travis WITH GRANT OPTION;"
  could not change directory to "/home/travis/build/getpatchwork/patchwork": Permission denied
  psql: could not connect to server: No such file or directory
    Is the server running locally and accepting
    connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5433"?

Use the solution from [2] to resolve it.

[1] https://travis-ci.org/getpatchwork/patchwork/jobs/582342649
[2] https://github.com/travis-ci/travis-ci/issues/8537#issuecomment-498299645

Signed-off-by: Stephen Finucane <stephen@that.guru>
.travis.yml

index d3f6d7025b0239585602c7129a71f5e4758681a0..cc326840cdb21289961f6647663b9047443a9626 100644 (file)
@@ -33,20 +33,10 @@ matrix:
         - PW_TEST_DB_USER=root
     - addons:
         postgresql: 10
-        apt:
-          packages:
-          - postgresql-10
-          - postgresql-client-10
       env:
-        - PGPORT=5433
-        - PW_TEST_DB_HOST=""
-        - PW_TEST_DB_PORT=5433
         - PW_TEST_DB_TYPE=postgres
-        - PW_TEST_DB_USER=travis
+        - PW_TEST_DB_USER=postgres
       python: 3.7
-      sudo: true
-      before_install:
-        - sudo -u postgres psql -c "grant ALL on DATABASE postgres to travis WITH GRANT OPTION;"
 
 before_script:
   - if [[ $PW_TEST_DB_TYPE == mysql ]]; then mysql -e "create database patchwork character set utf8;"; fi