Merge branch 'devEnv' into 'master'

Add a docker-compose file



See merge request !1
This commit is contained in:
Lucas 2016-02-22 14:03:07 +00:00
commit d4b1fb725c
2 changed files with 23 additions and 3 deletions

View File

@ -1,5 +1,16 @@
# Run tests ## Setup the dev env
Use lastest postgres docker from https://hub.docker.com/r/library/postgres/ and run: Just run the docker-compose file to create the database.
env POSTGRES_DSN="postgres://test:test@192.168.99.100:32771/test?sslmode=disable" go test -v -p=1 ./...
```
docker-compose up -d
```
## Run the tests
```
POSTGRES_DSN="postgres://test:test@127.0.0.1:5432/test?sslmode=disable" go test -v -p=1 ./...
```

9
docker-compose.yml Normal file
View File

@ -0,0 +1,9 @@
postgresql:
image: postgres:9.5
container_name: canape_postgresql_dev
restart: always
environment:
- POSTGRES_PASSWORD=test
- POSTGRES_USER=test
ports:
- 127.0.0.1:5432:5432