mirror of
https://github.com/hakanensari/frankfurter.git
synced 2024-11-25 04:22:28 +01:00
Fix Travis
This commit is contained in:
parent
c1e1644c52
commit
e7fe4d8f44
18
.travis.yml
18
.travis.yml
@ -7,15 +7,25 @@ rvm:
|
|||||||
|
|
||||||
addons:
|
addons:
|
||||||
postgresql: 10
|
postgresql: 10
|
||||||
before_install:
|
apt:
|
||||||
- "psql -c 'create database frankfurter_test;' -U postgres"
|
packages:
|
||||||
|
- postgresql-10
|
||||||
|
- postgresql-client-10
|
||||||
|
|
||||||
services:
|
services:
|
||||||
- docker
|
- docker
|
||||||
|
|
||||||
bundler_args: "--without development test"
|
before_install:
|
||||||
|
- sudo sed -i -e '/local.*peer/s/postgres/all/' -e 's/peer\|md5/trust/g' /etc/postgresql/*/main/pg_hba.conf
|
||||||
|
- sudo service postgresql restart
|
||||||
|
- sleep 1
|
||||||
|
- psql -c 'create database frankfurter_test;' -U postgres
|
||||||
|
|
||||||
|
bundler_args: --without development
|
||||||
env:
|
env:
|
||||||
- APP_ENV=test
|
global:
|
||||||
|
- APP_ENV=test
|
||||||
|
- PGPORT=5433
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
provider: script
|
provider: script
|
||||||
|
@ -6,5 +6,5 @@ require 'sequel'
|
|||||||
Sequel.extension :pg_json_ops
|
Sequel.extension :pg_json_ops
|
||||||
Sequel.single_threaded = true
|
Sequel.single_threaded = true
|
||||||
Sequel.connect(ENV['DATABASE_URL'] ||
|
Sequel.connect(ENV['DATABASE_URL'] ||
|
||||||
"postgres://localhost/frankfurter_#{App.env}")
|
"postgres://localhost:#{ENV['PGPORT']}/frankfurter_#{App.env}")
|
||||||
.extension :pg_json
|
.extension :pg_json
|
||||||
|
Loading…
Reference in New Issue
Block a user