Reputation: 26311
I installed https://github.com/gitlabhq/gitlab-recipes/tree/master/install/centos.
One of the steps was to delete /etc/httpd/conf.d/ssl.conf
(actually rename to ssl.conf.bak), and add a new gitlab.conf
file.
How does Apache know which file to use in /etc/httpd/conf.d? I would have thought that I would have had to edit /etc/httpd/conf/httpd.conf
, and specify the file, but this does not appear to be the case. Does Apache just use any file with a .conf
extension located in /etc/httpd/conf.d/
? If so, would an error occur if there was more than one?
Upvotes: 10
Views: 27215
Reputation: 86545
It depends on how the server is configured. But it's common to have a line similar to this:
Include conf.d/*.conf
in the main config (or some other config file included by it). That will include all the .conf
files in the conf.d
directory.
Other groups of files could be set up the same way, by simply adding a similar line(with a different directory name, of course). Ubuntu, for example, has a directory named sites-enabled
that contains files to set up the sites active on the server.
Upvotes: 24