From b506792846d13e5b0438a9a8695137d200d5d5c6 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 12 Oct 2011 00:00:57 +0200 Subject: send mail to owner with password the newlist script by mailman ask for an "ENTER" to send a mail to the owner so we have to emulate this --- util.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util.py b/util.py index 0709d58..1b8aa5c 100644 --- a/util.py +++ b/util.py @@ -41,7 +41,9 @@ def create_list(listname, listadmin, passwd=None): # create list p = subprocess.Popen(['sudo', '-n', os.path.join(config.mailman_path, 'bin', 'neueliste.bash'), listname, listadmin, passwd], - stdout=subprocess.PIPE, stderr=subprocess.STDOUT) + stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE) + print >>p.stdin, "" + (progress, junk) = p.communicate() return (p.returncode == 0, progress) except Exception as e: -- cgit v1.2.3-1-g7c22