{
listen = {
addrs = [
"[::]" // Default; this covers IPv4 & IPv6
]
tls_port = 443 // Default
// Default; this is implied by the ACME config
// Non-ACME traffic will redirect to TLS
// insecure_port = 80
}
vhosts = [
{
hostname = "www.example.com"
// Optional aliases for this host. These will be added to
// the generated TLS certificate.
aliases = [
"docs.example.com"
"pics.example.com"
]
tls = {
acme = {
contact = "admin@example.com"
// This implicitly enables port 80 above
challenge.type = "http-01"
profile = "shortlived"
}
}
backends = [
{
// A service that does not allow a custom root/context,
// so we must place at root.
context = "/"
url = "https://localhost:8443"
// This service enforces TLS with a self-signed cert, so
// we need to disable certificate verification.
trust = true
}
{
// A better behaved service that allows a custom root.
context = "/copyparty"
url = "http://localhost:9090"
}
]
}
]
}