I have a postfix installed on my machine, and I update virtual_alias on the fly programmatically (using python) (for some actions). As soon as I update the entry in the / etc / postfix / virtual _alias file, I run the command:
sudo /usr/sbin/postmap /etc/postfix/virtual_alias 2>>/work/postfix_valias_errorfile
But I get an error message:
sudo: sorry, you must have a tty to run sudo
I want to run the indicated sudo command in a non-human way (this means that I am running this system command from a python script.). So how can I run this command programmatically?
python linux root sudo sysadmin
None-da Feb 24 '09 at 19:32 2009-02-24 19:32
source share