LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] Redirects http to https

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: [lvs-users] Redirects http to https
From: Samy Ascha <samy@xxxxxx>
Date: Wed, 24 Jul 2013 10:05:13 +0200
Brian,

The simplest solution, and the one I would implement, is to reserve a special 
URL for the ldirectord HTTP(80) check. This URL should not be matched by your 
301 redirect configuration, but rather just return a HTTP 200 response. This 
would make sure the check knows whether your HTTP-server is online. Then, like 
you already did, you make a check for HTTPS in the same way.

Now, when director checks your servers, it won't encounter the 301.

> How can I get my http traffic on 80 always routed to https on 443 with LVS?


You should not be doing that. You should let the web server decide where 
invalid/unwanted request should be redirected. If you are going to route 80 too 
443 your in a whole new world of trouble. You don't want to use 
https://example.com:80/ for your encrypted traffic right? That makes no sense.

Met vriendelijke groet,
Samy Ascha


> Brian,
> 
> LVS operates at Layer 4 and therefore has no capability to do Layer 7
> re-directs.
> You would need to use HAProxy (or preferably your application cluster to do 
> it.)
> 
> 
> 
> 
> On 24 July 2013 04:36, Brian <ba221400@xxxxxxxxx> wrote:
>> Thanks Samy. I am not sure what you mean though--I'm not doing anything
>> specific to ldirectord with the 301. I'm simply doing a redirect with my
>> web server to send http to https.
>> 
>> I'm still stuck on this one. Does anyone have experience routing their http
>> traffic to https with lvs?
>> 
> 
> 
> 
> 
> -- 
> Regards,
> 
> Malcolm Turnbull.
> 
> Loadbalancer.org Ltd.
> Phone: +44 (0)870 443 8779
> http://www.loadbalancer.org/
> 
> _______________________________________________
> Please read the documentation before posting - it's available at:
> http://www.linuxvirtualserver.org/
> 
> LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
> Send requests to lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
> or go to http://lists.graemef.net/mailman/listinfo/lvs-users


_______________________________________________
Please read the documentation before posting - it's available at:
http://www.linuxvirtualserver.org/

LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Send requests to lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
or go to http://lists.graemef.net/mailman/listinfo/lvs-users

<Prev in Thread] Current Thread [Next in Thread>