Quote:
Originally Posted by tara
Hi,
I wish to allow a user to use sudo to run a single command (service app status) to determine if my application app is running, in my sudoers file i have:
user ALL= /sbin/service app status
I understand that there is a parameter called timestamp_timeout that will set the timeout for the 'user', but requires at least 1 entry of the root password.
I wish to allow the user to do "sudo service app status" and not have to enter the root password ever(maybe once is ok), but still make the user enter the root password for all other root activities. Is there a way to prevent the password entry for this command only and no others??
Thanks in advance.
|
actually what i posted before is correct...
Code:
# Cmnd alias specification
Cmnd_Alias SVSTAT = /usr/local/bin/svstat
# User privilege specification
nagios ALL=SVSTAT, NOPASSWD: SVSTAT
example above says that the user called nagios can run the /usr/local/bin/svstat command without needing to enter a password.