-
Notifications
You must be signed in to change notification settings - Fork 11
/
.travis.yml
45 lines (39 loc) · 1.16 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
dist: jammy
sudo: required
language: python
python: "3.11"
addons:
postgresql: "13"
apt:
packages:
- postgresql-13
- postgresql-client-13
services:
- postgresql
before_install:
- nvm install 20
# Specify trust instead of peer authentication for Postgres
- >-
sudo sed -i
-e '/local.*peer/s/postgres/all/'
-e 's/peer\|md5/trust/g'
/etc/postgresql/13/main/pg_hba.conf
# Restart the Postgres service
- sudo service postgresql@13-main restart
env:
global:
# See https://docs.travis-ci.com/user/database-setup/#using-a-different-postgresql-version
- PGPORT=5433
- PGVER=13
install:
- npm install
- pip3 install tox
script:
- psql -c 'create database boac_test;' -U postgres
- psql -c 'create database boac_loch_test;' -U postgres
- psql boac_test -c 'create extension pg_trgm;' -U postgres
- psql boac_test -c 'create role boac superuser login; alter schema public owner to boac;' -U postgres
- psql boac_loch_test -c 'create extension pg_trgm;' -U postgres
- psql boac_loch_test -c 'alter schema public owner to boac;' -U postgres
- pip3 install -r requirements.txt
- tox --parallel || travis_terminate 1