Munin, apache and how to password protect munin

user959129 picture user959129 · Feb 3, 2012 · Viewed 13.2k times · Source

I am using apache2 and munin server on Ubuntu. How do I password protect domain.com/munin with this username and password

admin/test101

Here is the location of my munin htmldir:

htmldir /var/cache/munin/www

Answer

Leon picture Leon · Mar 12, 2012

You could add basic authication to apache folder using .htaccess If you munin locate at /var/www/munin , you can do like this edit file /var/www/munin/.htaccess , put the follow content there

   AuthType Basic
   AuthName "Members Only"
   AuthUserFile /var/www/munin/.htpasswd
   <limit GET PUT POST>
   require valid-user
   </limit>

run command htpasswd /var/www/munin/.htpasswd admin to set password for admin user