-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
43 lines (42 loc) · 1.18 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
services:
ghost:
image: ghost:latest
container_name: ghost
restart: always
ports:
- "${GHOST_PORT}:2368"
depends_on:
db:
condition: service_healthy
environment:
url: ${GHOST_URL}
database__client: mysql
database__connection__host: db
database__connection__user: ${DB_USER}
database__connection__password: ${DB_PASS}
database__connection__database: ${DB_DB}
mail__transport: ${MAIL_TRANSPORT}
mail__from: ${SMTP_FROM}
mail__options__host: ${SMTP_HOST}
mail__options__name: ${SMTP_HOST}
mail__options__port: ${SMTP_PORT:-587}
mail__options__auth__user: ${SMTP_USER}
mail__options__auth__pass: ${SMTP_PASSWORD}
volumes:
- ./content:/var/lib/ghost/content
command: ["node", "current/index.js"]
db:
image: mysql:9.2
restart: always
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASS}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASS}
MYSQL_DATABASE: ${DB_DB}
volumes:
- ./mysql:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 10s
timeout: 5s
retries: 15