]> Raphaƫl G. Git Repositories - ihttpd/blob - SOURCES/ihttpd.conf
2286c1eeb9251f7db6f0995d03463c64e88d47aa
[ihttpd] / SOURCES / ihttpd.conf
1 # Fix server root
2 #XXX: useless now ???
3 ServerRoot "/etc"
4
5 # Listen on port 80 and 443
6 Listen 80
7 Listen 443
8
9 # Server admin
10 ServerAdmin root@localhost
11
12 # Fix user
13 User root
14 Group root
15
16 # Send charset
17 AddDefaultCharset UTF-8
18
19 # Allow file send
20 EnableSendfile on
21
22 # Set timeout
23 Timeout 600
24
25 # Set document root
26 DocumentRoot "/var/www/html"
27
28 <Directory />
29 AllowOverride None
30 </Directory>
31 <Directory "/run/ihttpd/log">
32 AllowOverride None
33 Require all granted
34 </Directory>
35 <Directory "/var/www/html">
36 AllowOverride None
37 Options Indexes FollowSymLinks ExecCGI
38 Require all granted
39 DirectoryIndex index.bin
40 AddHandler cgi-script .bin
41 </Directory>
42
43 # Fix mime type file location
44 TypesConfig /etc/mime.types
45
46 # Fix pid location
47 PidFile /run/ihttpd/ihttpd.pid
48
49 # Fix dir for rewrite map lock files
50 Mutex file:/run/ihttpd rewrite-map
51 Mutex file:/run/ihttpd mpm-accept
52
53 # Disable version info
54 ServerSignature Off
55 ServerTokens Prod
56
57 # SSL configuration
58 SSLCipherSuite HIGH:MEDIUM:!aNULL:!MD5
59 SSLSessionCache shmcb:/run/ihttpd/ssl_scache(512000)
60 SSLProtocol all -SSLv3
61
62 # Redirect to https
63 RewriteEngine On
64 RewriteCond %{HTTPS} !=on
65 RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
66
67 # SSL vhost
68 <VirtualHost *:443>
69 ServerName localhost
70 SSLEngine on
71 SSLCertificateFile /etc/pki/tls/certs/ihttpd.pem
72 SSLCertificateKeyFile /etc/pki/tls/private/ihttpd.pem
73 CustomLog "/run/ihttpd/log/https.log" "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
74 </VirtualHost>
75
76 # Log section
77 ErrorLog "/run/ihttpd/log/error.log"
78 LogLevel warn
79
80 <IfModule log_config_module>
81 CustomLog "/run/ihttpd/log/http.log" "%h %l %u %t \"%r\" %>s %b"
82 </IfModule>