mirror of
https://github.com/hakanensari/frankfurter.git
synced 2024-11-22 02:52:49 +01:00
Fix Travis
This commit is contained in:
parent
c1e1644c52
commit
e7fe4d8f44
16
.travis.yml
16
.travis.yml
@ -7,15 +7,25 @@ rvm:
|
||||
|
||||
addons:
|
||||
postgresql: 10
|
||||
before_install:
|
||||
- "psql -c 'create database frankfurter_test;' -U postgres"
|
||||
apt:
|
||||
packages:
|
||||
- postgresql-10
|
||||
- postgresql-client-10
|
||||
|
||||
services:
|
||||
- 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:
|
||||
global:
|
||||
- APP_ENV=test
|
||||
- PGPORT=5433
|
||||
|
||||
deploy:
|
||||
provider: script
|
||||
|
@ -6,5 +6,5 @@ require 'sequel'
|
||||
Sequel.extension :pg_json_ops
|
||||
Sequel.single_threaded = true
|
||||
Sequel.connect(ENV['DATABASE_URL'] ||
|
||||
"postgres://localhost/frankfurter_#{App.env}")
|
||||
"postgres://localhost:#{ENV['PGPORT']}/frankfurter_#{App.env}")
|
||||
.extension :pg_json
|
||||
|
Loading…
Reference in New Issue
Block a user