Hi all,

I have a registration form where users, amongst other things, choose a number of mailing lists to sign up to. I don't want users to have to go and individually sign up to each list, so I'm trying to automate the signup process.

After doing a bit of reading around, the closest I've got is to generate a plaintext file of email addresses for each newsletter and then use a cron command to sign these up, using the add_users program.

To test, I've been running this cron command:

echo t...@testing.co.uk | /usr/local/cpanel/3rdparty/mailman/bin/add_members -r - info

Where info is the listname (i...@nanotp.org)

I get the following error:

Traceback (most recent call last):
  File "/usr/local/cpanel/3rdparty/mailman/bin/add_members", line 258, in ?
    main()
File "/usr/local/cpanel/3rdparty/mailman/bin/add_members", line 211, in main
    mlist = MailList.MailList(listname)
File "/usr/local/cpanel/3rdparty/mailman/Mailman/MailList.py", line 128, in __init__
    self.Lock()
File "/usr/local/cpanel/3rdparty/mailman/Mailman/MailList.py", line 161, in Lock
    self.__lock.lock(timeout)
File "/usr/local/cpanel/3rdparty/mailman/Mailman/LockFile.py", line 243, in lock
    self.__write()
File "/usr/local/cpanel/3rdparty/mailman/Mailman/LockFile.py", line 422, in __write
    fp = open(self.__tmpfname, 'w')
IOError: [Errno 13] Permission denied: '/usr/local/cpanel/3rdparty/mailman/locks/info.lock.hephaestus.safeukdns.net.24247.0'

I tried check_perms -f and get the same error:

/usr/local/cpanel/3rdparty/mailman/bin/check_perms -f

Warning: Private archive directory is other-executable (o+x).
This could allow other users on your system to read private archives.
         If you're on a shared multiuser system, you should consult the
         installation manual on how to fix this.
Traceback (most recent call last):
  File "/usr/local/cpanel/3rdparty/mailman/bin/check_perms", line 399, in ?
    checkarchivedbs()
File "/usr/local/cpanel/3rdparty/mailman/bin/check_perms", line 258, in checkarchivedbs
    for dir in os.listdir(mm_cfg.PRIVATE_ARCHIVE_FILE_DIR):
OSError: [Errno 13] Permission denied: '/usr/local/cpanel/3rdparty/mailman/archives/private'


Can anyone suggest a way to get around this problem? Or an alternative method of automating signups (they can be totally silent). I have tried a similar method using the PHP exec() command to hit the same program but had similar permission problems.

Cheers,

Phil
------------------------------------------------------
Mailman-Users mailing list Mailman-Users@python.org
http://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Security Policy: http://wiki.list.org/x/QIA9
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
http://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Reply via email to