-
-
Notifications
You must be signed in to change notification settings - Fork 66
/
docker-compose.yaml
63 lines (59 loc) · 1.55 KB
/
docker-compose.yaml
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
services:
caddy:
image: ghcr.io/amalshaji/caddy-docker-proxy:main
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- caddy_data:/data
restart: unless-stopped
network_mode: "host"
admin:
image: amalshaji/portr-admin:0.0.20-beta
network_mode: "host"
env_file: .env
restart: unless-stopped
depends_on:
postgres:
condition: service_healthy
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/api/v1/healthcheck"]
interval: 10s
timeout: 5s
retries: 5
labels:
caddy_0: $PORTR_DOMAIN
caddy_0.reverse_proxy: "{{upstreams http 8000}}"
caddy_0.encode: gzip
tunnel:
image: amalshaji/portr-tunnel:0.0.20-beta
command: ["start"]
network_mode: "host"
env_file: .env
restart: unless-stopped
depends_on:
admin:
condition: service_healthy
postgres:
condition: service_healthy
labels:
caddy_1: "*.$PORTR_DOMAIN"
caddy_1.reverse_proxy: "{{upstreams http 8001}}"
caddy_1.tls.dns: "cloudflare $CLOUDFLARE_API_TOKEN"
caddy_1.encode: gzip
postgres:
image: postgres:16.2
network_mode: "host"
environment:
POSTGRES_USER: $POSTGRES_USER
POSTGRES_PASSWORD: $POSTGRES_PASSWORD
POSTGRES_DB: $POSTGRES_DB
volumes:
- postgres_data:/var/lib/postgresql/data
restart: unless-stopped
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $POSTGRES_USER"]
interval: 10s
timeout: 5s
retries: 5
volumes:
postgres_data: {}
caddy_data: {}