Configure passenger to allow Twitter login when using Varnish

I have an idea about that. but in my case i face this problem.

it redirect to port 80.
What i have to do now?

should i add passenger_set_cgi_param SERVER_PORT 80; to my discourse.conf?
i already try that and when i restart nginx i got this

nginx: [emerg] unknown directive "passenger_set_cgi_param" in /etc/nginx/conf.d/discourse.conf:21

nginx: configuration file /etc/nginx/nginx.conf test failed

Does it should be redirect to port 443?

sorry for my bad English.