Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apache2 BootCamp : Using Apache to Serve Static Content
1. #5
Day #2
Using Apache to Serve Static Content
Wildan Maulana
wildan.m@openthinklabs.com
http://workshop.openthinklabs.com
2. Overview
● How to configure Apache to listen on different
IP addresses and ports
● How to organize the URL space with directory
aliasing and redirection
● How to customize the server information and
error messages
4. Customizing the Web Server
● Error Messages
● International Error Messages
● Handling URL Errors: mod_speling
● Customizing Server Information
● Server Identification
● Contact Information
5. Customizing the Web Server
Error Messages
ErrorDocument
ErrorDocument 500 http://foo.example.com/cgi-bin/tester
ErrorDocument 404 /cgi-bin/bad_urls.pl
ErrorDocument 401 /subscription_info.html
ErrorDocument 403 "Sorry can't allow you access today"
6. Customizing the Web Server
International Error Messages
Server Side Includes (mod_include) and content
negotiation (mod_negotiation).
Custom Error Codes
8. Customizing the Web Server
Server Identification & Contact Information
ServerTokens Options
Settings Output
ServerTokens ProductOnly Apache
ServerTokens Minimal Apache/2.0.28
ServerTokens OS Apache/2.0.28 (Unix)
ServerTokens Full Apache/2.0.28 (Unix) SSL/2.0. 0
ServerSignature On/Off
ServerAdmin admin@email.example.com
9. Aliasing and Mapping of Resources
Alias /icons/ /usr/local/apache2/icons/
AliasMatch ^/help(.*) /usr/local/apache/htdocs/manual$1