-
Notifications
You must be signed in to change notification settings - Fork 41
/
docker-compose.yml
49 lines (47 loc) · 1.11 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
version: '2.1'
services:
proxy:
image: jwilder/nginx-proxy
ports:
- "80:80"
- "443:443"
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
database:
image: mariadb
environment:
- MYSQL_ROOT_PASSWORD=password
- MYSQL_DATABASE=lobsters
healthcheck:
test: "/usr/bin/mysql --user=root --password=password --execute \"SHOW DATABASES;\""
timeout: 5s
retries: 20
volumes:
- 'lobsters_database:/var/lib/mysql'
app:
image: utensils/lobsters:latest
build:
context: .
args:
DEVELOPER_BUILD: "false"
environment:
- MARIADB_HOST=database
- MARIADB_PORT=3306
- MARIADB_PASSWORD=password
- MARIADB_USER=root
- LOBSTER_DATABASE=lobsters
- LOBSTER_SITE_NAME="Example News"
- RAILS_ENV=development
- LOBSTER_HOSTNAME=localhost
- VIRTUAL_HOST=localhost
- RAILS_MAX_THREADS=5
ports:
- "3000:3000"
depends_on:
database:
condition: service_healthy
proxy:
condition: service_started
volumes:
lobsters_database:
driver: local