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?
All the configuration files for Apache are located in /etc/httpd/conf and /etc/httpd/conf.
The main configuration file is usually called httpd. conf . The location of this file is set at compile-time, but may be overridden with the -f command line flag. In addition, other configuration files may be added using the Include directive, and wildcards can be used to include many configuration files.
HTTPd stands for Hypertext Transfer Protocol daemon. It usually is the main software part of an HTTP server better known as a web server.
If you installed httpd from source, the default location of the configuration files is /usr/local/apache2/conf . The default configuration file is usually called httpd. conf .
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.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With