generated from hackforla/.github-hackforla-base-repo-template
-
-
Notifications
You must be signed in to change notification settings - Fork 21
/
docker-compose.yml
83 lines (83 loc) · 1.98 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
services:
db:
image: postgres
restart: always
volumes:
- db-data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=huu
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_PORT=5432
ports:
- "5432:5432"
pgadmin:
image: dpage/pgadmin4
volumes:
- pgadmin-data:/var/lib/pgadmin
environment:
- PGADMIN_DEFAULT_PASSWORD=pgadmin
- PGADMIN_CONFIG_SERVER_MODE=False
- PGADMIN_CONFIG_MASTER_PASSWORD_REQUIRED=False
entrypoint: /bin/sh -c "chmod 600 /pgpass; /entrypoint.sh;"
user: root
configs:
- source: servers.json
target: /pgadmin4/servers.json
- source: pgpass
target: /pgpass
ports:
- "5050:80"
depends_on:
- db
motoserver:
image: motoserver/moto:latest
ports:
- "5000:5000"
environment:
- MOTO_PORT=5000
backend:
build:
context: ./backend
ports:
- "8000:8000"
environment:
- COGNITO_CLIENT_ID=testing
- COGNITO_CLIENT_SECRET=testing
- COGNITO_REGION=us-east-1
- COGNITO_REDIRECT_URI=http://localhost:4040/signin
- COGNITO_USER_POOL_ID=testing
- COGNITO_ACCESS_ID=testing
- COGNITO_ACCESS_KEY=testing
- COGNITO_ENDPOINT_URL=http://motoserver:5000
- ROOT_URL=http://localhost:4040
- DATABASE_URL=postgresql+psycopg2://postgres:postgres@db:5432/huu
links:
- db
depends_on:
- pgadmin
- motoserver
frontend:
build:
context: ./frontend
ports:
- "4040:80"
volumes:
db-data: {}
pgadmin-data: {}
configs:
pgpass:
content: db:5432:*:postgres:postgres
servers.json:
content: |
{"Servers": {"1": {
"Group": "Servers",
"Name": "Home Unite Us",
"Host": "db",
"Port": 5432,
"MaintenanceDB": "postgres",
"Username": "postgres",
"PassFile": "/pgpass",
"SSLMode": "prefer"
}}}