forked from webstudio-is/webstudio
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
71 lines (61 loc) · 2.14 KB
/
docker-compose.yml
File metadata and controls
71 lines (61 loc) · 2.14 KB
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
version: "3.8"
services:
app:
init: true
privileged: true
build:
context: .
dockerfile: Dockerfile
volumes:
- ..:/workspaces/webstudio:cached
# preserve history
- ./.local:/home/node/.local
- docker-data:/var/lib/docker
entrypoint: ["/usr/local/share/docker-init.sh"]
# Overrides default command so things don't shut down after the process ends.
command: sleep infinity
# Runs app on the same network as the database container, allows "forwardPorts" in devcontainer.json function.
network_mode: service:db
depends_on:
db:
condition: service_healthy
db:
image: ghcr.io/supabase/postgres:15.1.1.55
# Uncomment to log all queries
command: ["postgres", "-c", "log_statement=all", "-c", "listen_addresses=*"]
restart: unless-stopped
volumes:
- postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: pass
POSTGRES_DB: webstudio
ports:
- ${PGPORT:-5432}:5432
- 3000:3000
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d webstudio"]
interval: 10s
timeout: 5s
retries: 25
rest:
container_name: supabase-rest
image: postgrest/postgrest:v12.2.0
depends_on:
db:
# Disable this if you are using an external Postgres database
condition: service_healthy
restart: unless-stopped
environment:
PGRST_DB_URI: postgresql://postgres:pass@localhost/webstudio
PGRST_DB_SCHEMAS: ${PGRST_DB_SCHEMAS:-public}
PGRST_DB_ANON_ROLE: anon
PGRST_JWT_SECRET: ${JWT_SECRET:-jwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecret}
PGRST_DB_USE_LEGACY_GUCS: "false"
PGRST_APP_SETTINGS_JWT_SECRET: ${JWT_SECRET:-jwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecretjwtsecret}
PGRST_APP_SETTINGS_JWT_EXP: ${JWT_EXPIRY}
command: "postgrest"
# Runs app on the same network as the database container, allows "forwardPorts" in devcontainer.json function.
network_mode: service:db
volumes:
postgres-data:
docker-data: