Add missing TCP IPAllowList middleware constructor
Co-authored-by: Romain <rtribotte@users.noreply.github.com>
This commit is contained in:
parent
9adf0fb638
commit
eff294829f
3 changed files with 16 additions and 6 deletions
51
integration/fixtures/tcp/ip-allowlist.toml
Normal file
51
integration/fixtures/tcp/ip-allowlist.toml
Normal file
|
@ -0,0 +1,51 @@
|
|||
[global]
|
||||
checkNewVersion = false
|
||||
sendAnonymousUsage = false
|
||||
|
||||
[log]
|
||||
level = "DEBUG"
|
||||
|
||||
[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"
|
||||
middlewares = ["blocking-allowlist"]
|
||||
[tcp.routers.to-whoami-a.tls]
|
||||
passthrough = true
|
||||
|
||||
[tcp.routers.to-whoami-b]
|
||||
entryPoints = ["tcp"]
|
||||
rule = "HostSNI(`whoami-b.test`)"
|
||||
service = "whoami-b"
|
||||
middlewares = ["allowing-allowlist"]
|
||||
[tcp.routers.to-whoami-b.tls]
|
||||
passthrough = true
|
||||
|
||||
[tcp.services]
|
||||
[tcp.services.whoami-a.loadBalancer]
|
||||
[[tcp.services.whoami-a.loadBalancer.servers]]
|
||||
address = "{{ .WhoamiA }}"
|
||||
|
||||
[tcp.services.whoami-b.loadBalancer]
|
||||
[[tcp.services.whoami-b.loadBalancer.servers]]
|
||||
address = "{{ .WhoamiB }}"
|
||||
|
||||
[tcp.middlewares]
|
||||
[tcp.middlewares.allowing-allowlist.ipAllowList]
|
||||
sourceRange = ["127.0.0.1/32"]
|
||||
[tcp.middlewares.blocking-allowlist.ipAllowList]
|
||||
sourceRange = ["127.127.127.127/32"]
|
Loading…
Add table
Add a link
Reference in a new issue