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 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51
| # /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
utilisateur serveur =(root) NOPASSWD: /bin/cp /etc/freeradius/clients.conf ../backups/mgmt/etc/freeradius/clients.conf, /bin/cp /etc/sudoers ../backups/mgmt/etc/sudoers, /bin/chmod o+r ../backups/mgmt/etc/freeradius/clients.conf, /bin/chmod o+r ../backups/mgmt/etc/sudoers
# Allow members of group sudo to execute any command
# (Note that later entries override this, so you might need to move
# it further down)
%sudo ALL=(ALL) ALL
#
#includedir /etc/sudoers.d
## BEGIN: CENTREON SUDO
#Add by CENTREON installation script
User_Alias CENTREON=www-data,nagios
Defaults:CENTREON !requiretty
# Nagios Restart
CENTREON ALL = NOPASSWD: /etc/init.d/nagios* restart
CENTREON ALL = NOPASSWD: /etc/init.d/nagios restart
# Nagios reload
CENTREON ALL = NOPASSWD: /etc/init.d/nagios* reload
CENTREON ALL = NOPASSWD: /etc/init.d/nagios reload
# Nagios test config
CENTREON ALL = NOPASSWD: /usr/local/nagios/bin/nagios* -v *
CENTREON ALL = NOPASSWD: /usr/local/nagios/bin/nagios -v *
# Nagios test for optim config
CENTREON ALL = NOPASSWD: /usr/local/nagios/bin/nagios* -s *
CENTREON ALL = NOPASSWD: /usr/local/nagios/bin/nagios -s *
# Snmptrapd Restart
CENTREON ALL = NOPASSWD: /etc/init.d/snmptrapd restart
# CentStorage Restart
CENTREON ALL = NOPASSWD: /etc/init.d/centstorage restart
# CentStorage stop
CENTREON ALL = NOPASSWD: /etc/init.d/centstorage stop
# CentStorage start
CENTREON ALL = NOPASSWD: /etc/init.d/centstorage start
## END: CENTREON SUDO |