-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
39 lines (37 loc) · 968 Bytes
/
docker-compose.yml
File metadata and controls
39 lines (37 loc) · 968 Bytes
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
name: ssl-proxy-${DOMAIN:-localhost}
services:
mkcert:
build:
context: .
dockerfile: Dockerfile.mkcert
container_name: mkcert-${DOMAIN:-localhost}
hostname: ${DOMAIN:-localhost}
profiles:
- setup
environment:
- DOMAIN=${DOMAIN:-localhost}
volumes:
- ./certs:/certs
caddy:
build:
context: .
dockerfile: Dockerfile.caddy
container_name: ssl-proxy-${DOMAIN:-localhost}
ports:
- "${HTTP_PORT:-8080}:80"
- "${HTTPS_PORT:-8443}:443"
environment:
- DOMAIN=${DOMAIN:-localhost}
- UPSTREAM_URL=${UPSTREAM_URL:-http://host.docker.internal:3000}
- HTTPS_PORT=${HTTPS_PORT:-8443}
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ./config/Caddyfile:/etc/caddy/Caddyfile:ro
- ./certs:/etc/caddy/certs:ro
- caddy_data:/data
- caddy_config:/config
restart: unless-stopped
volumes:
caddy_data:
caddy_config: