traefik/integration/fixtures/tcp/ip-allowlist.toml

54 lines
1.2 KiB
TOML
Raw Normal View History

2021-06-11 13:30:05 +00:00
[global]
checkNewVersion = false
sendAnonymousUsage = false
[log]
level = "DEBUG"
noColor = true
2021-06-11 13:30:05 +00:00
2024-01-10 09:47:44 +00:00
2021-06-11 13:30:05 +00:00
[entryPoints]
[entryPoints.tcp]
address = ":8093"
[api]
insecure = true
[providers.file]
filename = "{{ .SelfFilename }}"
## dynamic configuration ##
[tcp]
[tcp.routers]
[tcp.routers.to-whoami-a]
entryPoints = ["tcp"]
rule = "HostSNI(`whoami-a.test`)"
service = "whoami-a"
2022-10-26 15:16:05 +00:00
middlewares = ["blocking-ipallowlist"]
2024-01-10 09:47:44 +00:00
[tcp.routers.to-whoami-a.tls]
passthrough = true
2021-06-11 13:30:05 +00:00
[tcp.routers.to-whoami-b]
entryPoints = ["tcp"]
rule = "HostSNI(`whoami-b.test`)"
service = "whoami-b"
2022-10-26 15:16:05 +00:00
middlewares = ["allowing-ipallowlist"]
2024-01-10 09:47:44 +00:00
[tcp.routers.to-whoami-b.tls]
passthrough = true
2021-06-11 13:30:05 +00:00
[tcp.services]
[tcp.services.whoami-a.loadBalancer]
[[tcp.services.whoami-a.loadBalancer.servers]]
address = "{{ .WhoamiA }}"
2021-06-11 13:30:05 +00:00
[tcp.services.whoami-b.loadBalancer]
[[tcp.services.whoami-b.loadBalancer.servers]]
address = "{{ .WhoamiB }}"
2021-06-11 13:30:05 +00:00
2024-01-10 09:47:44 +00:00
[tcp.middlewares]
[tcp.middlewares.allowing-ipallowlist.ipAllowList]
sourceRange = ["127.0.0.1/32"]
[tcp.middlewares.blocking-ipallowlist.ipAllowList]
sourceRange = ["127.127.127.127/32"]