-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
86 lines (80 loc) · 1.86 KB
/
docker-compose.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
version: '3'
services:
mailhog:
image: mailhog/mailhog
networks:
- test_network
postgres:
image: postgres:9.5
environment:
- POSTGRES_PASSWORD=root
- POSTGRES_DB=poc_features
networks:
- test_network
redis:
image: redis
networks:
- test_network
app:
image: registry.heroku.com/peaceful-refuge-95132/web
environment:
# NOTICE: uncomment this if you need to display logs for debugging
#- RAILS_LOG_TO_STDOUT=true
- RAILS_ENV=features
- MAILHOG_HOST=mailhog
- RAILS_MASTER_KEY
- "GITHUB_CLIENT_ID=${FEATURES_GITHUB_CLIENT_ID}"
- "GITHUB_SECRET=${FEATURES_GITHUB_SECRET}"
- GITHUB_CALLBACK_DOMAIN=http://www.app.com:3000
- PGHOST=postgres
- REDIS_URL=redis://redis:6379
- RECAPTCHA_SITE_KEY
- RECAPTCHA_SECRET_KEY
depends_on:
- postgres
- redis
- mailhog
networks:
test_network:
aliases:
- app.com
- www.app.com
command: >
/bin/bash -c "
while ! nc -z postgres 5432;
do
echo Waiting for PG;
sleep 1;
done;
rake db:schema:load;
rm -f /app/tmp/pids/server.pid;
foreman start;
"
features:
image: symbiod/symbiod-features:${CURRENT_TAG}
container_name: features_1
depends_on:
- app
environment:
- CUCUMBER_HOST=http://www.app.com:3000
- PGHOST=postgres
- GITHUB_TEST_EMAIL
- GITHUB_TEST_PASSWORD
- GITHUB_NON_PUBLIC_EMAIL
- GITHUB_NON_PUBLIC_PASSWORD
networks:
- test_network
volumes:
- ./artifacts:/app/artifacts
command: >
/bin/bash -c "
while ! nc -z www.app.com 3000;
do
echo Waiting for app;
sleep 1;
done;
cucumber;
"
networks:
test_network:
driver: bridge