forked from amplication/amplication
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
38 lines (38 loc) · 1.09 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
version: "3"
services:
postgres:
image: postgres:12
restart: always
environment:
POSTGRES_USER: ${POSTGRESQL_USER}
POSTGRES_PASSWORD: ${POSTGRESQL_PASSWORD}
volumes:
- postgres:/var/lib/postgresql/data
app:
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
environment:
POSTGRESQL_URL: postgres://${POSTGRESQL_USER}:${POSTGRESQL_PASSWORD}@postgres:5432
JWT_SECRET: "${JWT_SECRET}"
SERVICE_JWT_SECRET: "${SERVICE_JWT_SECRET}"
BCRYPT_SALT_OR_ROUNDS: "${BCRYPT_SALT_OR_ROUNDS}"
NODE_ENV: production
CORS_ENABLE: 1
PORT: 3000
HOST: http://localhost:3000
DEFAULT_DISK: "${DEFAULT_DISK}"
LOCAL_DISK_ROOT: "${LOCAL_DISK_ROOT}"
CONTAINER_BUILDER_DEFAULT: "${CONTAINER_BUILDER_DEFAULT}"
GENERATED_APP_BASE_IMAGE: "${GENERATED_APP_BASE_IMAGE}"
migrate:
build:
context: .
dockerfile: Dockerfile
environment:
POSTGRESQL_URL: postgres://${POSTGRESQL_USER}:${POSTGRESQL_PASSWORD}@postgres:5432
command: npm run migrate:up
volumes:
postgres: ~