Refactor Traefik configuration to add Spice proxy support

This commit is contained in:
2024-09-11 13:48:20 +08:00
parent 1cf3f085c6
commit 4762e28af4
2 changed files with 35 additions and 2 deletions
+8
View File
@@ -25,6 +25,12 @@ services:
- target: 8084
published: 8084
mode: host
- target: 3128
published: 3128
mode: host
- target: 61001
published: 61001
mode: host
# - target: 8883
# published: 8883
# mode: host
@@ -133,6 +139,8 @@ services:
- --entrypoints.web-socket.address=:8083
- --entrypoints.web-socket-secure.address=:8084
- --entrypoints.bolt-socket.address=:7687
- --entrypoints.spice-socket.address=:3128
- --entrypoints.spice-tls-socket.address=:61001
# Create the certificate resolver "le" for Let's Encrypt, uses the environment variable EMAIL
- --certificatesresolvers.le.acme.email=${EMAIL?Variable not set}
# Store the Let's Encrypt certificates in the mounted volume
+27 -2
View File
@@ -12,7 +12,7 @@ http:
- admin-auth@swarm
tls: {}
service: coco_desktop@file
local-proxmox00:
entryPoints:
- https
@@ -56,7 +56,6 @@ http:
service: proxmox01@file
services:
coco_desktop:
loadBalancer:
servers:
@@ -75,3 +74,29 @@ http:
serversTransport: "pvetransport"
servers:
- url: "https://192.168.50.201:8006"
tcp:
routers:
spice:
entryPoints:
- spice
rule: HostSNI(`*`)
tls: false
service: spice@file
spice-tls:
entryPoints:
- spice-tls
rule: HostSNI(`*`)
tls:
passthrough: true
service: spice-tls@file
services:
spice:
loadBalancer:
servers:
- address: "https://192.168.50.210:3128"
spice-tls:
loadBalancer:
servers:
- address: "https://192.168.50.210:61001"