Docs: Fix from-to-www redirect description. (#11712)

This commit is contained in:
dvglab 2024-08-01 13:28:03 +03:00 committed by GitHub
parent e972a35e98
commit c6e86c86dc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -657,7 +657,7 @@ To preserve the trailing slash in the URI with `ssl-redirect`, set `nginx.ingres
In some scenarios, it is required to redirect from `www.domain.com` to `domain.com` or vice versa, which way the redirect is performed depends on the configured `host` value in the Ingress object.
For example, if `.spec.rules.host` is configured with a value like `www.example.com`, then this annotation will redirect to `example.com`. If `.spec.rules.host` is configured with a value like `example.com`, so without a `www`, then this annotation will redirect to `www.example.com` instead.
For example, if `.spec.rules.host` is configured with a value like `www.example.com`, then this annotation will redirect from `example.com` to `www.example.com`. If `.spec.rules.host` is configured with a value like `example.com`, so without a `www`, then this annotation will redirect from `www.example.com` to `example.com` instead.
To enable this feature use the annotation `nginx.ingress.kubernetes.io/from-to-www-redirect: "true"`