Skip to content

Commit 5cc54c7

Browse files
committed
OCPBUGS-33700:Added routes note for soure IP address in IController doc
1 parent 53581c8 commit 5cc54c7

File tree

2 files changed

+49
-5
lines changed

2 files changed

+49
-5
lines changed

modules/nw-ingress-controller-configuration-proxy-protocol.adoc

Lines changed: 42 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Module included in the following assemblies:
22
//
3-
// * ingress/configure-ingress-operator.adoc
3+
// * networking/ingress-operator.adoc
44

55
:_mod-docs-content-type: PROCEDURE
66
[id="nw-ingress-controller-configuration-proxy-protocol_{context}"]
@@ -10,7 +10,25 @@ A cluster administrator can configure link:https://www.haproxy.org/download/1.8/
1010

1111
[WARNING]
1212
====
13-
The PROXY protocol is unsupported for the default Ingress Controller with installer-provisioned clusters on non-cloud platforms that use a Keepalived Ingress VIP.
13+
The default Ingress Controller with installer-provisioned clusters on non-cloud platforms that use a Keepalived Ingress Virtual IP (VIP) do not support the PROXY protocol.
14+
====
15+
16+
The PROXY protocol enables the load balancer to preserve the original client addresses for connections that the Ingress Controller receives. The original client addresses are useful for logging, filtering, and injecting HTTP headers. In the default configuration, the connections that the Ingress Controller receives contain only the source IP address that is associated with the load balancer.
17+
18+
[IMPORTANT]
19+
====
20+
For a passthrough route configuration, servers in {product-title} clusters cannot observe the original client source IP address. If you need to know the original client source IP address, configure Ingress access logging for your Ingress Controller so that you can view the client source IP addresses.
21+
22+
For re-encrypt and edge routes, the {product-title} router sets the `Forwarded` and `X-Forwarded-For` headers so that application workloads check the client source IP address.
23+
24+
For more information about Ingress access logging, see "Configuring Ingress access logging".
25+
====
26+
27+
Configuring the PROXY protocol for an Ingress Controller is not supported when using the `LoadBalancerService` endpoint publishing strategy type. This restriction is because when {product-title} runs in a cloud platform, and an Ingress Controller specifies that a service load balancer should be used, the Ingress Operator configures the load balancer service and enables the PROXY protocol based on the platform requirement for preserving source addresses.
28+
29+
[IMPORTANT]
30+
====
31+
You must configure both {product-title} and the external load balancer to use either the PROXY protocol or TCP.
1432
====
1533

1634
This feature is not supported in cloud deployments. This restriction is because when {product-title} runs in a cloud platform, and an Ingress Controller specifies that a service load balancer should be used, the Ingress Operator configures the load balancer service and enables the PROXY protocol based on the platform requirement for preserving source addresses.
@@ -24,7 +42,7 @@ You must configure both {product-title} and the external load balancer to either
2442
* You created an Ingress Controller.
2543
2644
.Procedure
27-
. Edit the Ingress Controller resource:
45+
. Edit the Ingress Controller resource by entering the following command in your CLI:
2846
+
2947
[source,terminal]
3048
----
@@ -33,25 +51,44 @@ $ oc -n openshift-ingress-operator edit ingresscontroller/default
3351

3452
. Set the PROXY configuration:
3553
+
36-
* If your Ingress Controller uses the hostNetwork endpoint publishing strategy type, set the `spec.endpointPublishingStrategy.hostNetwork.protocol` subfield to `PROXY`:
54+
* If your Ingress Controller uses the `HostNetwork` endpoint publishing strategy type, set the `spec.endpointPublishingStrategy.hostNetwork.protocol` subfield to `PROXY`:
3755
+
3856
.Sample `hostNetwork` configuration to `PROXY`
3957
[source,yaml]
4058
----
59+
# ...
4160
spec:
4261
endpointPublishingStrategy:
4362
hostNetwork:
4463
protocol: PROXY
4564
type: HostNetwork
65+
# ...
4666
----
47-
* If your Ingress Controller uses the NodePortService endpoint publishing strategy type, set the `spec.endpointPublishingStrategy.nodePort.protocol` subfield to `PROXY`:
67+
68+
* If your Ingress Controller uses the `NodePortService` endpoint publishing strategy type, set the `spec.endpointPublishingStrategy.nodePort.protocol` subfield to `PROXY`:
4869
+
4970
.Sample `nodePort` configuration to `PROXY`
5071
[source,yaml]
5172
----
73+
# ...
5274
spec:
5375
endpointPublishingStrategy:
5476
nodePort:
5577
protocol: PROXY
5678
type: NodePortService
79+
# ...
80+
----
81+
82+
* If your Ingress Controller uses the `Private` endpoint publishing strategy type, set the `spec.endpointPublishingStrategy.private.protocol` subfield to `PROXY`:
83+
+
84+
.Sample `private` configuration to `PROXY`
85+
[source,yaml]
86+
----
87+
# ...
88+
spec:
89+
endpointPublishingStrategy:
90+
private:
91+
protocol: PROXY
92+
type: Private
93+
# ...
5794
----

networking/ingress-operator.adoc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,15 @@ include::modules/nw-using-ingress-forwarded.adoc[leveloffset=+2]
9494

9595
include::modules/nw-http2-haproxy.adoc[leveloffset=+2]
9696

97+
// Configuring the PROXY protocol for an Ingress Controller
9798
include::modules/nw-ingress-controller-configuration-proxy-protocol.adoc[leveloffset=+2]
9899

100+
[role="_additional-resources"]
101+
.Additional resources
102+
103+
* xref:../networking/ingress-operator.adoc#nw-configure-ingress-access-logging_configuring-ingress[Configuring Ingress access logging]
104+
105+
// Specifying an alternative cluster domain using the appsDomain option
99106
include::modules/nw-ingress-configuring-application-domain.adoc[leveloffset=+2]
100107

101108
include::modules/nw-ingress-converting-http-header-case.adoc[leveloffset=+2]

0 commit comments

Comments
 (0)