可以traefik redirect example.com/test到192.168.1.1:8888没有路径



是否可以将域/路径重定向到没有路径的内部服务器?IE HXXP://example.com/test重定向到内部服务器192.168.1.1:8888

我使用supdomains的traefik启动并运行,但是一旦我尝试使用遇到问题的路径。我尝试过pathprefixstrip无济于事。

这是在我的QNAP服务器上的Docker中运行的。

[frontends.test1]
    backend = "test1"
    entrypoints = ["https"]
        [frontends.tes1t.routes.test1]
        rule = "Host:example.com;PathPrefixStrip /test"
[backends.test1]
            [backends.test1.servers.test1]
            url = "hxxps://192.168.1.1:8888"

尝试使用PathPrefixStrip:/test代替PathPrefixStrip /test(在同一想法中,您使用Host:example.com而不是Host example.com

最新更新