mirror of
https://github.com/michivonah/bbzw-horizon.git
synced 2025-12-22 17:16:27 +01:00
add Caddy as reverse proxy
This commit is contained in:
parent
bec06107dc
commit
afce0130e1
2 changed files with 34 additions and 0 deletions
25
caddy/Caddyfile
Normal file
25
caddy/Caddyfile
Normal file
|
|
@ -0,0 +1,25 @@
|
||||||
|
<DOMAIN> {
|
||||||
|
handle_path /api/* {
|
||||||
|
rewrite /api/* /{http.request.uri.path.4}
|
||||||
|
reverse_proxy webservice-inp21b:8080
|
||||||
|
}
|
||||||
|
|
||||||
|
handle / {
|
||||||
|
reverse_proxy frontend:5173
|
||||||
|
}
|
||||||
|
|
||||||
|
tls internal
|
||||||
|
}
|
||||||
|
|
||||||
|
http://<DOMAIN> {
|
||||||
|
handle_path /api/* {
|
||||||
|
rewrite /api/* /{http.request.uri.path.4}
|
||||||
|
reverse_proxy webservice-inp21b:8080
|
||||||
|
}
|
||||||
|
|
||||||
|
handle / {
|
||||||
|
reverse_proxy frontend:5173
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -21,6 +21,7 @@ services:
|
||||||
- 8080:8080
|
- 8080:8080
|
||||||
environment:
|
environment:
|
||||||
- DB_CONNECTION_STRING=postgresql://bbzw-horizon:<PW>@db/bbzw-horizon
|
- DB_CONNECTION_STRING=postgresql://bbzw-horizon:<PW>@db/bbzw-horizon
|
||||||
|
- CRYPTO_SUBSTITION_KEY=""
|
||||||
|
|
||||||
frontend:
|
frontend:
|
||||||
build:
|
build:
|
||||||
|
|
@ -42,3 +43,11 @@ services:
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
user: 0:0
|
user: 0:0
|
||||||
|
|
||||||
|
caddy:
|
||||||
|
image: caddy:2.10
|
||||||
|
ports:
|
||||||
|
- "80:80"
|
||||||
|
- "443:443"
|
||||||
|
volumes:
|
||||||
|
- ./caddy/Caddyfile:/etc/caddy/Caddyfile
|
||||||
|
restart: unless-stopped
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue