> > > If it's instead 80, something else is running web2py that reports > > remote_port as 80. > > Or web2py is setting remote_port to 80 itself? > > it can't . you won't find any piece of code that fiddles setting remote_port. it's an environmental variable that is only read by web2py.
> > Well, on the same hosting, iow. same nginx at the front-end, I run few > PHP sites which are served by Hiawatha web serving also listening on > similar localport. > > If I try simple test.php script, no matter which port is forwarded, iow. > no matter whether I use http/https to access the script, phpinfo() > reports that SERVER_PORT = localport where Hiawatha server is listening > and all the apps are working as expected. > you're comparing apple to oranges. php and python don't share any bit of the configuration if you're serving web2py on gunicorn. > > E.g. in #flask I'm told: "Flask works fine behind remote proxies but you > do need to take care of setting the Host and X-Forwarded-For headers > correctly." > > I'll try to research more and check nginx setup, although it works with > all the other apps. > it works fine even with web2py (as said before, any wsgi app has access to the same exact environment and treats some of those headers in the same exact way, because they are established standards): you're only missing a few details of your own setup. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

