Installation - creating the mailman.cfg permissions
https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-insta...
Following the instructions (at the above URL) to create the mailman.cfg, I'm getting a permissions problem when trying to do so as user "mailman" .
Although the instructions say to create the file as user "mailman", should it be created by root (with/without virtualenv?) and then chown to "mailman"?
Make sure that you are running commands as mailman user from here forth.
root@mx:/# su mailman
Create the virtualenv for Mailman:
mailman@mx:/$ cd /opt/mailman mailman@mx:~$ python3 -m venv venv
Activate the created virtualenv:
mailman@mx:~$ source /opt/mailman/venv/bin/activate
The rest of this documentation assumes that virtualenv is activated.
Installing Mailman Core
(venv) mailman@mx:~$ pip install wheel mailman psycopg2-binary ...Successfully installed...
After this, create a configuration file at /etc/mailman3/mailman.cfg for Mailman Core:
(venv) mailman@mx:~$ nano /etc/mailman3/mailman.cfg [ Directory '/etc/mailman3' does not exist ]
(venv) mailman@mx:~$ mkdir /etc/mailman3 mkdir: cannot create directory ‘/etc/mailman3’: Permission denied
Mark Dale via Mailman-users writes:
Although the instructions say to create the file as user "mailman", should it be created by root (with/without virtualenv?) and then chown to "mailman"?
Yes. Since the file is created with a text editor, whether you're in a virtual environment or not is irrelevant (unless your preferred text editor is installed only in the virtual environment).
I guess that's an oversight in the documentation. Thanks for the report.
Steve
On 13-09-2021 08:40, Stephen J. Turnbull wrote:
Mark Dale via Mailman-users writes:
Although the instructions say to create the file as user "mailman", should it be created by root (with/without virtualenv?) and then chown to "mailman"?
Yes. Since the file is created with a text editor, whether you're in a virtual environment or not is irrelevant (unless your preferred text editor is installed only in the virtual environment).
I guess that's an oversight in the documentation. Thanks for the report.
I think the relevant point is that the documentation instructs you to execute the command to invoke the text editor as user 'mailman3', which will not work since user mailman3 won't have access to create files in /etc.
Cheers,
Koen
On 9/13/21 1:23 AM, Koen Martens wrote:
On 13-09-2021 08:40, Stephen J. Turnbull wrote:
Mark Dale via Mailman-users writes:
> Although the instructions say to create the file as user "mailman", > should it be created by root (with/without virtualenv?) and then > chown to "mailman"?
Yes. Since the file is created with a text editor, whether you're in a virtual environment or not is irrelevant (unless your preferred text editor is installed only in the virtual environment).
I guess that's an oversight in the documentation. Thanks for the report.
+1
I think the relevant point is that the documentation instructs you to execute the command to invoke the text editor as user 'mailman3', which will not work since user mailman3 won't have access to create files in /etc.
Yeah, I opened a ticket1 to fix that aspect, I think there should be a
note that any changes in /etc
should be made using sudo
or root
user.
The files inside /etc/mailman3 should be readable by mailman
user, but
it doesn't have to writable by it.
Cheers,
Koen
Mailman-users mailing list -- mailman-users@mailman3.org To unsubscribe send an email to mailman-users-leave@mailman3.org https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
-- thanks, Abhilash Raj (maxking)
participants (4)
-
Abhilash Raj
-
Koen Martens
-
Mark Dale
-
Stephen J. Turnbull