1 / 11

CITA 310 Section 4

CITA 310 Section 4. Apache Configuration. Directives and Containers. Statements in the Apache configuration file are called directives. A directive normally consists of a name followed by one or more parameters.

etheln
Download Presentation

CITA 310 Section 4

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CITA 310 Section 4 Apache Configuration

  2. Directives and Containers • Statements in the Apache configuration file are called directives. • A directive normally consists of a name followed by one or more parameters. • A directive can also be a container that consists of HTML-like starting and ending tags to group a set of directives.

  3. Basic Directives • ServerRoot • Directory location of server files • DocumentRoot • Directory where the Web pages are stored • ServerName • DNS host name or IP address of server

  4. Basic Directives • DirectoryIndex • Tells Apache to use the specified file(s) when a directory is queried • User • Shows the user name that Apache employs when someone requests a Web page

  5. Other Directives • Listen (80 by default) • Determines the port number for the server • KeepAlive (On by default) • Indicates whether Apache should maintain a persistent connection • ServerSignature (Off by default) • Controls whether the server information is displayed as a result of Web page error

  6. Directory Containers • <Directory> and </Directory> are used to enclose a group of directives that will apply only to the named directory and sub-directories of that directory. • Directory path is either the full path to a directory, or a wild-card string using Unix shell-style matching.

  7. Wild-Card String • ? matches any single character. • * matches any sequences of characters. • You may also use [] character ranges. • None of the wildcards match a slash (/) character.

  8. DirectoryMatch Containers • <DirectoryMatch> and </DirectoryMatch> are used to enclose a group of directives which will apply only to the named directory and sub-directories of that directory, the same as <Directory>. • However, it takes as an argument a regular expression.

  9. Files Containers • <Files> and </Files> limit the scope of the enclosed directives by filename. • The directives given within this section will be applied to any object with a basename (last component of filename) matching the specified filename.

  10. Location Containers • <Location> and </Location> limit the scope of the enclosed directives by URL. • It is recommended to use Location container to apply directives to content that lives outside the file system.

  11. Modules • An Apache administrator can choose the functionality to include in the server by selecting a set of modules. • The LoadModule directive links in the object file and adds the module structure to the list of active modules.

More Related