On 4/23/24 14:59, Mark wrote:
The welcome message is returned.
root@hel:~# sudo -u mailman curl https://LISTS.MYDOMAIN.COM/mailman3/api/templates/list/MYTESTLIST.LISTS.MYDO... Test Welcome message for new subscribers.root@hel:~#
I don't know what the issue is. curl, running as user mailman, is able to get the url, but Mailman core, presumably running as user mailman, times out trying to get the url. I can't explain why.
Try the following in mailman shell
running as user mailman
(venv) $ mailman shell
Welcome to the GNU Mailman shell
Use commit() to commit changes.
Use abort() to discard changes since the last commit.
Exit with ctrl+D does an implicit commit() but exit() does not.
>>> import requests
>>> r = requests.get(
...
'https://LISTS.MYDOMAIN.COM/mailman3/api/templates/list/MYTESTLIST.LISTS.MYDOMAIN.COM/list:user:notice:welcome',
... timeout=5)
>>> t.text
Note the URL above is all on one line.
This is exactly what Mailman core is doing to get the template assuming
the uri
in the template` table entry is the argument of the
requests.get().
If this times out, try increasing the timeout= value.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan