I'm currently using Apache as proxy for my LXD containers, using this kind of settings:
<VirtualHost *:80>
ServerName example.com
ProxyRequests off
ProxyPass / http://10.0.0.142/ retry=0
ProxyPassReverse / http://10.0.0.142/
ProxyPreserveHost On
</VirtualHost>
I would like to switch to traefik. I have tried this configuration:
defaultEntryPoints = ["http"]
[entryPoints]
[entryPoints.http]
address = ":80"
[backends]
[backends.backend1]
[backends.backend1.servers.server1]
url = "http://10.0.0.142"
[frontends]
[frontends.frontend1]
backend = "backend1"
passHostHeader = true
[frontends.frontend1.routes.example]
rule = "Host:example.com"
- Are these two equivalent?
- Can the traefik configuration be simplified? (remove unnecessary rules)
(Note: I'm not planning on using docker, and I would prefer not to.)