get the current hostname behind a mod_proxy installation
24 views
Skip to first unread message
Manuele Pesenti
unread,
Sep 9, 2020, 10:36:38 AM9/9/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web2py-users
Hi!!
Behind a mod_proxy apache virtual host how can I get within the server
side code witch hostname has been currently called? Considering at the
moment I have configured one hostname and more than one aliases I'd like
not to write the hostname directly ion the code.
Thanks a lot!
Manuele
Clemens
unread,
Sep 9, 2020, 10:44:29 AM9/9/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web2py-users
Does request.env.http_host gives us the information you want?
Manuele Pesenti
unread,
Sep 10, 2020, 2:48:48 AM9/10/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to web...@googlegroups.com
Actually I used request.env.HTTP_X_FORWARDED_SERVER I really
don't know if your answer fits anyway.