Run a linux system command as a superuser, using a python script

2009-02-24 Thread madhav
I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the configuration needs a reload, I need to reload postfix to reflect the latest change. How can I do that in a python script. Precisely, I

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread Chris Rebert
On Tue, Feb 24, 2009 at 11:38 AM, madhav madhav@gmail.com wrote: I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the configuration needs a reload, I need to reload postfix to

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread geremy condra
Run the script as root and have it drop privs when it doesn't need them. Or set up a separate daemon to do the rootish parts of it. -- http://mail.python.org/mailman/listinfo/python-list

Re: Run a linux system command as a superuser, using a python script

2009-02-24 Thread birdsong
On Feb 24, 11:44 am, Chris Rebert c...@rebertia.com wrote: On Tue, Feb 24, 2009 at 11:38 AM, madhav madhav@gmail.com wrote: I have got postfix installed on my machine and I am updating on of its configuration files programmatically(using python)(on some action). Since any change in the