[sudo-users] crontab modification using sudo
kashif anwar
sy.kashif at gmail.com
Mon Jul 9 11:16:14 EDT 2007
Hi All,
I need to modify the crontab by using sudo. can any body suggest me
something.
An "operator " account has been created for automatically modify the crontab
entry for different application users.
i ve allowed the user "operator " to run the following command
here is the entry
Host_Alias SERVERS = beryld0
User_Alias APPOPS = operator
Cmnd_Alias K_SCPT = /usr/bin/crontab -e tabstst
APPOPS SERVERS =(root) NOPASSWD: K_SCPT
this configuration should allow the user to modify the crontab for "tabstst"
with out passwd. but when we run the command in our script that doesnt
allowd us to edit the crontab successfully. here is the script calling for
this command
/usr/local/bin/sudo crontab -e tabstst<<EOF
:/^.*$script11/s/^#//g
:wq!
EOF"
if any one can suggest something , i will really apreciate.
thanks
Kashif
More information about the sudo-users
mailing list