D&C GLug - Home Page

[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]

Re: [LUG] Simpler Apache Virtual Hosts + SSL?

 

Simon Williams wrote:
>
> The config for each virtualhost is virtually identical, apart from 
> documentroot, servername and serveralias.

We have a /etc/apache2/include

When the script makes the virtual hosts, if it finds a file in this
directory with the Servername it chucks an "include" directive in.

This means we have near identical standard config for each host, and
just use the includes for "one offs" not handled by the script.

> So that means duplicating my entire virtualhosts section and changing 80 
> to 443.

There maybe better ways, but we have that approach in the script.

> Perhaps someone could also tell me what the accepted practice is for SSL:
> 1. SSL and non-SSL hosts share the same documentroot so that 
> https://site.com and http://site.com give the same thing
> 2. SSL is a subdirectory of the non-SSL site so that https://site.com is 
> the same as http://site.com/ssl
> 3. SSL and non-SSL have completely different documentroots.
> 4. Something else?

Whatever you need - we do 1 unless the client asks for something else.
Since for most people all they want if to put "https" is a few submit
actions, and it doesn't matter if people go out of their way to be insecure.

-- 
The Mailing List for the Devon & Cornwall LUG
http://mailman.dclug.org.uk/listinfo/list
FAQ: http://www.dcglug.org.uk/linux_adm/list-faq.html