This guide will help you setup Nagios user to have limited access to host and service checks. It is helpful when you want to allow your customers or clients to view and receive alerts on their servers and services, like for dedicated servers.
Contacts: Create new contact definitions for your client.
1 2 3 4 5 6 7 8 9 10 11
Groups: Create contact groups or you can add the new contact for you existing group, depending on the checks that you want to allow.
1 2 3 4 5
Hosts / Services: Use the new Contact Group with customers email and your main admin. Note that i used the existing Host Groups but you create new HostGroups if you want.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
In my case, I created a new group and add our admin contacts and customers, then update the contact groups for hosts and services. You can also create a new definitions for hosts, contacts, groups, and services with different names for the clients if you don’t want to edit your existing definitions.
Htaccess: Lastly, you need to add htaccess user to your htpasswd file (htpasswd.users). Username should match the name on your Contact. In this sample it is customer1. [Update] If you’ve implemented ”Digest Authentication” you need to update your digest file instead of the htpasswd.
Don’t forget to restart you Nagios.