As far as i know you can't force nginx to put the real source ip in the ip header.
I recommend to refactor the application to read the X-Real-IP header you set in your configuration.
If the application can't handle the X-Real-IP Header you can use HAProxy or Keepalived to achieve this.
For HAProxy you have to set the source in the backend configuration:
source 0.0.0.0 usesrc clientip
You have to enable the TPROXY module in Linux Kernel.
And the HAProxy System must be the default gateway for your application server to get this working.
You also have to configure some sysctl parameters:
net.ipv4.conf.all.forwarding => 1
net.ipv4.conf.all.send_redirects => 1
And some iptables rules:
iptables -t mangle -N DIVERT
iptables -t mangle -A PREROUTING -p tcp -m socket -j DIVERT
iptables -t mangle -A DIVERT -j MARK --set-mark 777
iptables -t mangle -A DIVERT -j ACCEPT
And configure the routing with firewall marks
ip rule add fwmark 777 lookup 700
ip route add local 0.0.0.0/0 dev lo table 700