On 8/11/21 4:18 AM, Richard Rosner wrote:
Mark Sapiro wrote:
You are in a better position to answer that than am I. What does sudo netstat -lntp show?
A lot. But since most of that isn't relevant here: Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:465 0.0.0.0:* LISTEN 20241/master tcp 0 0 127.0.0.1:8024 0.0.0.0:* LISTEN 14076/python3 tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 20241/master tcp 0 0 127.0.0.1:8001 0.0.0.0:* LISTEN 14080/python3
So some python3 process is listening on port 8001
tcp 0 0 0.0.0.0:587 0.0.0.0:* LISTEN 20241/master tcp6 0 0 :::80 :::* LISTEN 13882/apache2 tcp6 0 0 :::465 :::* LISTEN 20241/master tcp6 0 0 :::25 :::* LISTEN 20241/master tcp6 0 0 :::443 :::* LISTEN 13882/apache2 tcp6 0 0 :::587 :::* LISTEN 20241/master
What does ps -fwwa|grep rest show?
root 15055 14843 0 12:58 pts/1 00:00:00 grep rest
So whatever it's supposed to find, it's not there
But whatever is listening on port 8001 is apparently not Mailman's rest server. What does
ps -fww 14080
or whatever PID is currently listening on port 8001 show.
mailman3-web.service must also run as list.
I changed that. It didn't like it.
OK.
Perhaps instead you should have
uid: list gid: list
in your uwsgi configuration if you don't already.
So, what do you have in your apache config for proxying to uwsgi and what's your uwsgi configuration.
lists-ssl.conf: <VirtualHost *:443> ServerAdmin admin@domain.de ServerName lists.domain.de
Alias /mailman3/favicon.ico /var/lib/mailman3/web/static/postorius/img/favicon.ico Alias /mailman3/static /var/lib/mailman3/web/static
<Directory "/var/lib/mailman3/web/static"> Require all granted </Directory>
<IfModule mod_proxy_uwsgi.c> ProxyPass /mailman3/favicon.ico ! ProxyPass /mailman3/static ! ProxyPass "/mailman3" "unix:/run/mailman3-web/uwsgi.sock|uwsgi://localhost:8001/"
I'm not familiar enough with this form of ProxyPass using sockets to understand what the localhost:8001 does in this context, but uwsgi should not be doing anything with port 8001. In a configuration using TCP, it would listen on port 8000. Port 8001 is where Mailman's REST API server listens. uwsgi should receive connects in your case via the unix socket and then pass them to Django via the application in wsgi.py
Also, you may want other paths proxied to uwsgi, namely at least some of hyperkitty, postorius, archives, accounts, admin and user-profile.
</IfModule> ... I guess with uwsgi config you mean the /etc/mailman3/uwsgi.ini file? [uwsgi] # Port on which uwsgi will be listening. uwsgi-socket = /run/mailman3-web/uwsgi.sock
#Enable threading for python enable-threads = true
# Move to the directory wher the django files are. chdir = /usr/share/mailman3-web
# Use the wsgi file provided with the django project. wsgi-file = wsgi.py
# Setup default number of processes and threads per process. master = true process = 2 threads = 2
# Drop privielges and don't run as root. uid = www-data gid = www-data
These should be 'list', not 'www-data'. That's your permissions issue on settings.py
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan