[Nottingham] Struggling with some basic Apache config

J jasonirwin73 at gmail.com
Fri Apr 14 13:33:13 UTC 2017

>From what I've been reading, the setting defined for a VirtualHost apply
only to that VirtualHost; there's no concept of inheritance.

To save myself having to copy heaps of boilerplate (log locations, headers
etc) around all the VirtualHosts, is there anyway to achieve defaults (or
some kind of inheritance)?

1. Set some server-wide defaults.
2. Redirect all HTTP to HTTPS.
3. Add HTTPS-specifics to the defaults.
4. Have one application (accessed via "https://domain.tld/application_name")
override a couple of headers (mostly to do with the Content Security

The redirect works, HTTPS is also working, but unless I define all the
headers etc in there, they get ignored and I simply cannot figure out how
to do 4.

I've been reading the Apache docs and have either failed to understand or
not come across the relevant section.

Is what I want to do even possible?
Or am I simply going/thinking about this the wrong way and on a hiding to

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.lug.org.uk/pipermail/nottingham/attachments/20170414/57ae7e35/attachment.html>

More information about the Nottingham mailing list