What are the breaking changes, from v2 to v3, considering the ClientIP rule?

I am upgrading from v2 to v3-RC5 and followed the migration guide. Now, when I am running the Traefik container I get:

error while adding rule Host(xxx) && ClientIP(10.0.0.0/23, ::1): error while adding rule ClientIP: unexpected number of parameters; got 2, expected one of [1]

Do I simply remove the , ::1 part? I can't find anything related to this in the docs.

A lot of the rule matchers only take a single argument starting with v3, so you would need to use

.rule=ClientIP() || ClientIP()

All matchers now take a single value (except Header , HeaderRegexp , Query , and QueryRegexp which take two) and should be explicitly combined using logical operators to mimic previous behavior.

Source

1 Like

Thank you for the response.

I guess my question is, do I need the ::1 part?

I am under the impression that my colleague, that originally built the configuration, simply added it because they copy/pasted it from the docs.

Is there a reason to include the loopback address to the ClientIP rule?

If you want to connect via localhost IPv6, then you probably need it :wink:

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.