-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
49 lines (46 loc) · 1.17 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
services:
strapi:
container_name: strapi
build:
context: ./strapi
restart: unless-stopped
ports:
- "1337:1337"
environment:
STRAPI_ADMIN_BACKEND_URL: ${STRAPI_ADMIN_BACKEND_URL}
DATABASE_CLIENT: ${DATABASE_CLIENT}
DATABASE_HOST: ${DATABASE_HOST}
DATABASE_PORT: ${DATABASE_PORT}
DATABASE_NAME: ${DATABASE_NAME}
DATABASE_USERNAME: ${DATABASE_USERNAME}
DATABASE_PASSWORD: ${DATABASE_PASSWORD}
JWT_SECRET: ${JWT_SECRET}
ADMIN_JWT_SECRET: ${ADMIN_JWT_SECRET}
API_TOKEN_SALT: ${API_TOKEN_SALT}
APP_KEYS: ${APP_KEYS}
NODE_ENV: ${NODE_ENV}
depends_on:
- strapiDB
strapiDB:
image: postgres:14-alpine
restart: unless-stopped
ports:
- "5432:5432"
environment:
POSTGRES_USER: ${DATABASE_USERNAME}
POSTGRES_PASSWORD: ${DATABASE_PASSWORD}
POSTGRES_DB: ${DATABASE_NAME}
admin:
image: nginx:alpine
restart: unless-stopped
ports:
- "8080:80"
volumes:
- ./strapi/dist/build:/usr/share/nginx/html:ro
environment:
NGINX_HOST: localhost
NGINX_PORT: 80
depends_on:
- strapi
volumes:
postgres_data: