Hi there!
I’m trying to setup a system, where I bind multiple public IPs (both v4 and v6) and using proxying them to different backends. I would like it to work with any domain, but can’t make it work.
i’m either getting duplicate key error when I try to use just port as label, etc - or “site … is not served on this interface” when I use IP as label.
[ip:v6:ip::number1:as:label] {
bind ip:v6:ip::number1:as:label
proxy / http://backend3:80 http://backend4:80 {
transparent
}
tls {
max_certs 10
}
}
:80 :443 [ip:v6:ip::number2:as:label] {
bind ip:v6:ip::number2:as:label
proxy / http://backend5:80 http://backend6:80 {
transparent
}
tls {
max_certs 10
}
}
ipv4:address:here:number1:443 {
bind ipv4:address:here:number1
proxy / http://backend1:80 http://backend2:80 {
transparent
}
tls {
max_certs 10
}
}
* {
bind ipv4:address:here:number2
proxy / http://backend7:80 http://backend8:80 {
transparent
}
tls {
max_certs 10
}
}
I’ve also tried with *
- it works for one block, but when i try to use it for multiple - i’m getting:
error inspecting server blocks: duplicate site key: *
Right now my only option is to run multiple caddy daemons.