`I am running Nginx as ingress controller in GKE. I have installed ingress controller using terraform release to last chart version 4.7.0.
I am trying to comunicate with another aplication but application said that 2 ips are being received in [X-Forwarded-For] value from Request headers: One Is the Public ip of the client and the other is private ip from kuberntes nginx controller pod, but only client is needed. I just try to update config in values.yaml as follows but no able to get only Public Client Ip. Comments are possible solutions but nothing works.not able to set use proxy protocol either.
I am stuck. Please help. The config as follows it is inside nginx-values.yaml
controller:
config:
#enable-real-ip: "true"
compute-full-forwarded-for: "true"
use-forwarded-headers: "true"
force-ssl-redirect: "true"
#real-ip-header: "X-Forwarded-For"
#set_real_ip_from: "X.X.X.X/X"
#real_ip_recursive: "off"
#use-proxy-protocol: "true"
#proxy-add-original-uri-header: "true"
ingressClassResource:
name: external-nginx
enbaled: true
default: false
replicaCount: 2
autoscaling:
enabled: true
maxReplicas: 10
minReplicas: 2
admissionWebhooks:
enabled: false
service:
externalTrafficPolicy: "Local"
annotations:
cloud.google.com/load-balancer-type: External
get some solutions or anybody can help me`