576df0
#
576df0
# This is the main Apache HTTP server configuration file.  It contains the
576df0
# configuration directives that give the server its instructions.
576df0
# See <URL:http://httpd.apache.org/docs/2.4/> for detailed information.
576df0
# In particular, see 
576df0
# <URL:http://httpd.apache.org/docs/2.4/mod/directives.html>
576df0
# for a discussion of each configuration directive.
576df0
#
576df0
# See the httpd.conf(5) man page for more information on this configuration,
576df0
# and httpd.service(8) on using and configuring the httpd service.
576df0
#
576df0
# Do NOT simply read the instructions in here without understanding
576df0
# what they do.  They're here only as hints or reminders.  If you are unsure
576df0
# consult the online docs. You have been warned.  
576df0
#
576df0
# Configuration and logfile names: If the filenames you specify for many
576df0
# of the server's control files begin with "/" (or "drive:/" for Win32), the
576df0
# server will use that explicit path.  If the filenames do *not* begin
576df0
# with "/", the value of ServerRoot is prepended -- so 'log/access_log'
576df0
# with ServerRoot set to '/www' will be interpreted by the
576df0
# server as '/www/log/access_log', where as '/log/access_log' will be
576df0
# interpreted as '/log/access_log'.
576df0
576df0
#
576df0
# ServerRoot: The top of the directory tree under which the server's
576df0
# configuration, error, and log files are kept.
576df0
#
576df0
# Do not add a slash at the end of the directory path.  If you point
576df0
# ServerRoot at a non-local disk, be sure to specify a local disk on the
576df0
# Mutex directive, if file-based mutexes are used.  If you wish to share the
576df0
# same ServerRoot for multiple httpd daemons, you will need to change at
576df0
# least PidFile.
576df0
#
576df0
ServerRoot "/etc/httpd"
576df0
576df0
#
576df0
# Listen: Allows you to bind Apache to specific IP addresses and/or
576df0
# ports, instead of the default. See also the <VirtualHost>
576df0
# directive.
576df0
#
576df0
# Change this to Listen on specific IP addresses as shown below to 
576df0
# prevent Apache from glomming onto all bound IP addresses.
576df0
#
576df0
#Listen 12.34.56.78:80
576df0
Listen 80
576df0
576df0
#
576df0
# Dynamic Shared Object (DSO) Support
576df0
#
576df0
# To be able to use the functionality of a module which was built as a DSO you
576df0
# have to place corresponding `LoadModule' lines at this location so the
576df0
# directives contained in it are actually available _before_ they are used.
576df0
# Statically compiled modules (those listed by `httpd -l') do not need
576df0
# to be loaded here.
576df0
#
576df0
# Example:
576df0
# LoadModule foo_module modules/mod_foo.so
576df0
#
576df0
Include conf.modules.d/*.conf
576df0
576df0
#
576df0
# If you wish httpd to run as a different user or group, you must run
576df0
# httpd as root initially and it will switch.  
576df0
#
576df0
# User/Group: The name (or #number) of the user/group to run httpd as.
576df0
# It is usually good practice to create a dedicated user and group for
576df0
# running httpd, as with most system services.
576df0
#
576df0
User apache
576df0
Group apache
576df0
576df0
# 'Main' server configuration
576df0
#
576df0
# The directives in this section set up the values used by the 'main'
576df0
# server, which responds to any requests that aren't handled by a
576df0
# <VirtualHost> definition.  These values also provide defaults for
576df0
# any <VirtualHost> containers you may define later in the file.
576df0
#
576df0
# All of these directives may appear inside <VirtualHost> containers,
576df0
# in which case these default settings will be overridden for the
576df0
# virtual host being defined.
576df0
#
576df0
576df0
#
576df0
# ServerAdmin: Your address, where problems with the server should be
576df0
# e-mailed.  This address appears on some server-generated pages, such
576df0
# as error documents.  e.g. admin@your-domain.com
576df0
#
576df0
ServerAdmin root@localhost
576df0
576df0
#
576df0
# ServerName gives the name and port that the server uses to identify itself.
576df0
# This can often be determined automatically, but we recommend you specify
576df0
# it explicitly to prevent problems during startup.
576df0
#
576df0
# If your host doesn't have a registered DNS name, enter its IP address here.
576df0
#
576df0
#ServerName www.example.com:80
576df0
576df0
#
576df0
# Deny access to the entirety of your server's filesystem. You must
576df0
# explicitly permit access to web content directories in other 
576df0
# <Directory> blocks below.
576df0
#
576df0
<Directory />
576df0
    AllowOverride none
576df0
    Require all denied
576df0
</Directory>
576df0
576df0
#
576df0
# Note that from this point forward you must specifically allow
576df0
# particular features to be enabled - so if something's not working as
576df0
# you might expect, make sure that you have specifically enabled it
576df0
# below.
576df0
#
576df0
576df0
#
576df0
# DocumentRoot: The directory out of which you will serve your
576df0
# documents. By default, all requests are taken from this directory, but
576df0
# symbolic links and aliases may be used to point to other locations.
576df0
#
576df0
DocumentRoot "/var/www/html"
576df0
576df0
#
576df0
# Relax access to content within /var/www.
576df0
#
576df0
<Directory "/var/www">
576df0
    AllowOverride None
576df0
    # Allow open access:
576df0
    Require all granted
576df0
</Directory>
576df0
576df0
# Further relax access to the default document root:
576df0
<Directory "/var/www/html">
576df0
    #
576df0
    # Possible values for the Options directive are "None", "All",
576df0
    # or any combination of:
576df0
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
576df0
    #
576df0
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
576df0
    # doesn't give it to you.
576df0
    #
576df0
    # The Options directive is both complicated and important.  Please see
576df0
    # http://httpd.apache.org/docs/2.4/mod/core.html#options
576df0
    # for more information.
576df0
    #
576df0
    Options Indexes FollowSymLinks
576df0
576df0
    #
576df0
    # AllowOverride controls what directives may be placed in .htaccess files.
576df0
    # It can be "All", "None", or any combination of the keywords:
576df0
    #   Options FileInfo AuthConfig Limit
576df0
    #
576df0
    AllowOverride None
576df0
576df0
    #
576df0
    # Controls who can get stuff from this server.
576df0
    #
576df0
    Require all granted
576df0
</Directory>
576df0
576df0
#
576df0
# DirectoryIndex: sets the file that Apache will serve if a directory
576df0
# is requested.
576df0
#
576df0
<IfModule dir_module>
576df0
    DirectoryIndex index.html
576df0
</IfModule>
576df0
576df0
#
576df0
# The following lines prevent .htaccess and .htpasswd files from being 
576df0
# viewed by Web clients. 
576df0
#
576df0
<Files ".ht*">
576df0
    Require all denied
576df0
</Files>
576df0
576df0
#
576df0
# ErrorLog: The location of the error log file.
576df0
# If you do not specify an ErrorLog directive within a <VirtualHost>
576df0
# container, error messages relating to that virtual host will be
576df0
# logged here.  If you *do* define an error logfile for a <VirtualHost>
576df0
# container, that host's errors will be logged there and not here.
576df0
#
576df0
ErrorLog "logs/error_log"
576df0
576df0
#
576df0
# LogLevel: Control the number of messages logged to the error_log.
576df0
# Possible values include: debug, info, notice, warn, error, crit,
576df0
# alert, emerg.
576df0
#
576df0
LogLevel warn
576df0
576df0
<IfModule log_config_module>
576df0
    #
576df0
    # The following directives define some format nicknames for use with
576df0
    # a CustomLog directive (see below).
576df0
    #
576df0
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
576df0
    LogFormat "%h %l %u %t \"%r\" %>s %b" common
576df0
576df0
    <IfModule logio_module>
576df0
      # You need to enable mod_logio.c to use %I and %O
576df0
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
576df0
    </IfModule>
576df0
576df0
    #
576df0
    # The location and format of the access logfile (Common Logfile Format).
576df0
    # If you do not define any access logfiles within a <VirtualHost>
576df0
    # container, they will be logged here.  Contrariwise, if you *do*
576df0
    # define per-<VirtualHost> access logfiles, transactions will be
576df0
    # logged therein and *not* in this file.
576df0
    #
576df0
    #CustomLog "logs/access_log" common
576df0
576df0
    #
576df0
    # If you prefer a logfile with access, agent, and referer information
576df0
    # (Combined Logfile Format) you can use the following directive.
576df0
    #
576df0
    CustomLog "logs/access_log" combined
576df0
</IfModule>
576df0
576df0
<IfModule alias_module>
576df0
    #
576df0
    # Redirect: Allows you to tell clients about documents that used to 
576df0
    # exist in your server's namespace, but do not anymore. The client 
576df0
    # will make a new request for the document at its new location.
576df0
    # Example:
576df0
    # Redirect permanent /foo http://www.example.com/bar
576df0
576df0
    #
576df0
    # Alias: Maps web paths into filesystem paths and is used to
576df0
    # access content that does not live under the DocumentRoot.
576df0
    # Example:
576df0
    # Alias /webpath /full/filesystem/path
576df0
    #
576df0
    # If you include a trailing / on /webpath then the server will
576df0
    # require it to be present in the URL.  You will also likely
576df0
    # need to provide a <Directory> section to allow access to
576df0
    # the filesystem path.
576df0
576df0
    #
576df0
    # ScriptAlias: This controls which directories contain server scripts. 
576df0
    # ScriptAliases are essentially the same as Aliases, except that
576df0
    # documents in the target directory are treated as applications and
576df0
    # run by the server when requested rather than as documents sent to the
576df0
    # client.  The same rules about trailing "/" apply to ScriptAlias
576df0
    # directives as to Alias.
576df0
    #
576df0
    ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"
576df0
576df0
</IfModule>
576df0
576df0
#
576df0
# "/var/www/cgi-bin" should be changed to whatever your ScriptAliased
576df0
# CGI directory exists, if you have that configured.
576df0
#
576df0
<Directory "/var/www/cgi-bin">
576df0
    AllowOverride None
576df0
    Options None
576df0
    Require all granted
576df0
</Directory>
576df0
576df0
<IfModule mime_module>
576df0
    #
576df0
    # TypesConfig points to the file containing the list of mappings from
576df0
    # filename extension to MIME-type.
576df0
    #
576df0
    TypesConfig /etc/mime.types
576df0
576df0
    #
576df0
    # AddType allows you to add to or override the MIME configuration
576df0
    # file specified in TypesConfig for specific file types.
576df0
    #
576df0
    #AddType application/x-gzip .tgz
576df0
    #
576df0
    # AddEncoding allows you to have certain browsers uncompress
576df0
    # information on the fly. Note: Not all browsers support this.
576df0
    #
576df0
    #AddEncoding x-compress .Z
576df0
    #AddEncoding x-gzip .gz .tgz
576df0
    #
576df0
    # If the AddEncoding directives above are commented-out, then you
576df0
    # probably should define those extensions to indicate media types:
576df0
    #
576df0
    AddType application/x-compress .Z
576df0
    AddType application/x-gzip .gz .tgz
576df0
576df0
    #
576df0
    # AddHandler allows you to map certain file extensions to "handlers":
576df0
    # actions unrelated to filetype. These can be either built into the server
576df0
    # or added with the Action directive (see below)
576df0
    #
576df0
    # To use CGI scripts outside of ScriptAliased directories:
576df0
    # (You will also need to add "ExecCGI" to the "Options" directive.)
576df0
    #
576df0
    #AddHandler cgi-script .cgi
576df0
576df0
    # For type maps (negotiated resources):
576df0
    #AddHandler type-map var
576df0
576df0
    #
576df0
    # Filters allow you to process content before it is sent to the client.
576df0
    #
576df0
    # To parse .shtml files for server-side includes (SSI):
576df0
    # (You will also need to add "Includes" to the "Options" directive.)
576df0
    #
576df0
    AddType text/html .shtml
576df0
    AddOutputFilter INCLUDES .shtml
576df0
</IfModule>
576df0
576df0
#
576df0
# Specify a default charset for all content served; this enables
576df0
# interpretation of all content as UTF-8 by default.  To use the 
576df0
# default browser choice (ISO-8859-1), or to allow the META tags
576df0
# in HTML content to override this choice, comment out this
576df0
# directive:
576df0
#
576df0
AddDefaultCharset UTF-8
576df0
576df0
<IfModule mime_magic_module>
576df0
    #
576df0
    # The mod_mime_magic module allows the server to use various hints from the
576df0
    # contents of the file itself to determine its type.  The MIMEMagicFile
576df0
    # directive tells the module where the hint definitions are located.
576df0
    #
576df0
    MIMEMagicFile conf/magic
576df0
</IfModule>
576df0
576df0
#
576df0
# Customizable error responses come in three flavors:
576df0
# 1) plain text 2) local redirects 3) external redirects
576df0
#
576df0
# Some examples:
576df0
#ErrorDocument 500 "The server made a boo boo."
576df0
#ErrorDocument 404 /missing.html
576df0
#ErrorDocument 404 "/cgi-bin/missing_handler.pl"
576df0
#ErrorDocument 402 http://www.example.com/subscription_info.html
576df0
#
576df0
576df0
#
576df0
# EnableMMAP and EnableSendfile: On systems that support it, 
576df0
# memory-mapping or the sendfile syscall may be used to deliver
576df0
# files.  This usually improves server performance, but must
576df0
# be turned off when serving from networked-mounted 
576df0
# filesystems or if support for these functions is otherwise
576df0
# broken on your system.
576df0
# Defaults if commented: EnableMMAP On, EnableSendfile Off
576df0
#
576df0
#EnableMMAP off
576df0
EnableSendfile on
576df0
576df0
# Supplemental configuration
576df0
#
576df0
# Load config files in the "/etc/httpd/conf.d" directory, if any.
576df0
IncludeOptional conf.d/*.conf