-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
executable file
·55 lines (51 loc) · 1.3 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
version: "3.4"
# may need to comment out
services:
swatswap:
stdin_open: true
tty: true
build:
context: .
dockerfile: ./Dockerfile
volumes:
- .:/usr/src/app
environment:
NODE_ENV: development
DOMAIN: http://127.0.0.1:3000/
DATABASE_URL: ${DATABASE_URL}
ports:
- 3000:3000
env_file:
- .env
# may need to make .env
command: /bin/sh -c "npm install && timeout 22 sh -c 'until nc -z $0 $1; do sleep 1; done' swatswap-db 5432 && npx prisma migrate dev --name init && npx prisma generate && npm run dev"
swatswap-db:
image: postgres:16.1
container_name: swatswap-db
ports:
- 5432:5432
environment:
POSTGRES_USER: root
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: swatswap_db
env_file:
- .env
# may need to make .env
swatswap-minio-service:
image: minio/minio
command:
- server
- /data
- --console-address
- ":${MINIO_CONSOLE_PORT}"
container_name: swatswap-minio
ports:
- ${MINIO_PORT}:9000
- ${MINIO_CONSOLE_PORT}:${MINIO_CONSOLE_PORT}
environment:
MINIO_ROOT_USER: ${MINIO_ROOT_USER}
MINIO_ROOT_PASSWORD: ${MINIO_ROOT_PASSWORD}
volumes:
- swatswap-minio-data:/data
volumes:
swatswap-minio-data: