How to get real ip address behind a proxy server with rails

I’m having “Unknown User” problem at my issues detail page.
Using a system like below.

Client -> Nginx -> Rails

And using the gem ‘sentry-raven’ on my rails app.
At nginx, I’m passing X-Forwarded-For & X-Real-IP http headers but couldn’t find any configuration option to enable them on sentry gem.
I’ve tried to pass through using the user_context property like this.

id: 11111,
email: ‘’,
username: ‘useruser’,
ip_address: ‘’

Reffering to:

also like this.

Raven.user_context ip_address: ‘’

Success to send other variables, except “ip_address”.
Is there anyway to display the right client ip address at sentry admin page?

Looked up on: