httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Igor Cicimov <icici...@gmail.com>
Subject Re: [users@httpd] Virtual Hosts and SSL Config: Hoist Common Directives Above Server Blocks?
Date Wed, 12 Sep 2012 10:52:33 GMT
On Sep 9, 2012 10:58 PM, "Tom Browder" <tom.browder@gmail.com> wrote:
>
> I'm trying to clean up my conf files after getting an all-SSL server
> with several virtual hosts working.
>
> At the moment, for each server block, I have this:
>
> <IfModule mod_ssl.c>
> <VirtualHost *:443>
>   SSLEngine on
>
>   SSLCACertificateFile    /path/to/ca.pem
>   SSLCertificateFile         /path/to/server.crt
>   SSLCertificateKeyFile   /path/to/server.cert.key.unsecure
>   SSLCertificateChainFile /path/to/class2.server.ca.pem
>
>   ServerName  name.org
>   ServerAlias *.name.org
>
>   # more, server-specific info...
> </VirtualHost>
> </IfModule>
>
> Can I hoist the common SSL cert. stuff out of the server blocks to a
> higher, common block like this:
>
> <IfModule mod_ssl.c>
>   SSLEngine on
>   SSLCACertificateFile    /path/to/ca.pem
>   SSLCertificateFile         /path/to/server.crt
>   SSLCertificateKeyFile   /path/to/server.cert.key.unsecure
>   SSLCertificateChainFile /path/to/class2.server.ca.pem
> </IfModule>
>
> I would try it but I don't want to interrupt my server audiences in
> case it doesn't work.

Put the common blocks in a file and use Include statement for the file in
each of the hosts.

>
> Thanks.
>
> Best regards,
>
> -Tom
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>

Mime
View raw message