|
|
37236c4 |
# Example configuration for Apache httpd with cgi generated graphs.
|
|
|
37236c4 |
#
|
|
|
37236c4 |
# To use this example config file you need to enable cgi graphs in Munin. Add
|
|
|
37236c4 |
# following three lines to /etc/munin/conf.d/local.conf (without # character):
|
|
|
5c2cefb |
#
|
|
|
37236c4 |
# graph_strategy cgi
|
|
|
37236c4 |
# html_strategy cgi
|
|
|
37236c4 |
# cgiurl_graph /munin/graph
|
|
|
5c2cefb |
#
|
|
|
37236c4 |
# Then copy this file to /etc/httpd/conf.d/ directory and restart httpd.
|
|
|
37236c4 |
#
|
|
|
37236c4 |
# Access Munin at http://localhost/munin/
|
|
|
5c2cefb |
|
|
|
5c2cefb |
|
|
|
5c2cefb |
<VirtualHost *:80>
|
|
|
5c2cefb |
ServerName localhost
|
|
|
5c2cefb |
ServerAdmin root@localhost
|
|
|
5c2cefb |
ErrorLog /var/log/httpd/munin.localhost-error.log
|
|
|
5c2cefb |
CustomLog /var/log/httpd/munin.localhost-access.log combined
|
|
|
5c2cefb |
DocumentRoot /var/www/html
|
|
|
5c2cefb |
|
|
|
5c2cefb |
# Rewrites for graph/html generated by cgi
|
|
|
5c2cefb |
RewriteEngine On
|
|
|
5c2cefb |
RewriteRule ^/munin/static/(.*) /var/www/html/munin/static/$1 [L]
|
|
|
5c2cefb |
RewriteRule ^/munin/graph/(.*) /munin-cgi/munin-cgi-graph/$1 [L,PT]
|
|
|
5c2cefb |
RewriteRule ^/munin/(.*) /munin-cgi/munin-cgi-html/$1 [L,PT]
|
|
|
5c2cefb |
RewriteRule ^/munin$ /munin/ [R]
|
|
|
5c2cefb |
ScriptAlias /munin-cgi/ /var/www/html/munin/cgi/
|
|
|
5c2cefb |
|
|
|
5c2cefb |
# FastCGI
|
|
|
5c2cefb |
<Directory "/var/www/html/munin/cgi">
|
|
|
5c2cefb |
Options +ExecCGI
|
|
|
5c2cefb |
<IfModule mod_fcgid.c>
|
|
|
5c2cefb |
SetHandler fcgid-script
|
|
|
5c2cefb |
</IfModule>
|
|
|
5c2cefb |
<IfModule !mod_fcgid.c>
|
|
|
5c2cefb |
SetHandler cgi-script
|
|
|
5c2cefb |
</IfModule>
|
|
|
5c2cefb |
</Directory>
|
|
|
5c2cefb |
</VirtualHost>
|
|
|
b44176d |
|
|
|
b44176d |
|
|
|
b44176d |
# Uncomment following lines to require authentication:
|
|
|
b44176d |
|
|
|
b44176d |
# <Directory /var/www/html/munin>
|
|
|
b44176d |
# AuthUserFile /etc/munin/munin-htpasswd
|
|
|
b44176d |
# AuthName "Munin"
|
|
|
b44176d |
# AuthType Basic
|
|
|
b44176d |
# Require valid-user
|
|
|
b44176d |
# # This next part requires mod_expires to be enabled.
|
|
|
b44176d |
# #
|
|
|
b44176d |
# # We could use <IfModule mod_expires> around here, but I want it to be
|
|
|
b44176d |
# # as evident as possible that you either have to load mod_expires _or_
|
|
|
b44176d |
# # you coment out/remove these lines.
|
|
|
b44176d |
# #
|
|
|
b44176d |
# # Set the default expiery time for files 5 minutes 10 seconds from
|
|
|
b44176d |
# # their creation (modification) time. There are probably new files by
|
|
|
b44176d |
# # that time.
|
|
|
b44176d |
# ExpiresActive On
|
|
|
b44176d |
# ExpiresDefault M310
|
|
|
b44176d |
# </Directory>
|