Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I need to temporarily unmonitor a custom daemon when I deploy a new version. I tried monit unmonitor <name>, but it says I don't own monitrc since my deploy script does not run as root or have sudo priveliges for security reasons. Is there an easy way to get around this, to tell monit to let a non-root user start/stop/unmonitor a specific process?

(I could always use curl to accoplish this via the http interface, but just looking for a less hacky way)

share|improve this question
1  
perhaps there is some way to say 'if this file exists then unmonitor', and then I can just touch that file as the non-root user? –  Mohamed Hafez Mar 7 '13 at 3:20
    
I ended up getting around this problem by just enabling password-less sudo just for monit in my sudoers file: web ALL=(ALL) NOPASSWD: /usr/sbin/monit though i'd prefer it if the user web could only call monit for a specific process. –  Mohamed Hafez Mar 7 '13 at 15:08
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.