Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: Virtual Host with X-Forwarded-Proto for HAproxy and SSH |
|
Author |
|
giopas
Joined: 18 Nov 2015 Posts: 29
|
Posted: Mon 11 Jan '16 19:14 Post subject: Virtual Host with X-Forwarded-Proto for HAproxy and SSH |
|
|
Hi all,
I would need some support from an apache point of view to implement the solution in this article [1].
I have installed HAproxy, but I have not understood what/how to set a Virtual Host in apache (2.2.31) which would help in this situation.
In particular, I am not sure how to ensure 'X-Forwarded-Proto' is enabled and how to use it in such context.
Could someone please help me out with it please?
Thanks in advance,
giopas
[1] http://blog.chmd.fr/ssh-over-ssl-episode-4-a-haproxy-based-configuration.html |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7373 Location: Germany, Next to Hamburg
|
Posted: Wed 13 Jan '16 13:26 Post subject: |
|
|
What has HAproxy todo with apache? That tutorial is about SSH and HAproxy and not apache.
What are you trying to do? |
|
Back to top |
|
giopas
Joined: 18 Nov 2015 Posts: 29
|
Posted: Wed 13 Jan '16 13:36 Post subject: |
|
|
Humm, good question.
As far as I understood from that tutorial, to accomplish that you would need HAproxy, openssh-server and Apache.
In particular, it would be necessary for Apache to support 'X-Forwarded-Proto' headers and then, I think, it would be necessary to create a Virtual Host to have a specific subdomain linked to it.
What it is also not clear to me is the fact that the article speak about port 80 and http but then it uses SSL on port 443.
It is very likely that I am missing something and I would like to understand if from Apache point of view there is something I should do or check (e.g. how to check if I have 'X-Forwarded-Proto' enabled?) or if there is nothing to do on Apache side.
Thanks JB for your support!
giopas |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7373 Location: Germany, Next to Hamburg
|
|
Back to top |
|
giopas
Joined: 18 Nov 2015 Posts: 29
|
Posted: Wed 13 Jan '16 18:09 Post subject: |
|
|
The difference in your solution is that you need to change proxy settings from client side. With HAproxy, as far as I have understood, all would be done at the server side.
Or I am misreading it? |
|
Back to top |
|
|
|
|
|
|