Hello,

On Tue, Oct 01, 2024 at 11:08:19AM -0000, Chupin Maxime via Mailman-users wrote:
>  root@machine: sudo -u list bash

If you are root already, you could also use su:

su - -u list -s /bin/bash -c "mailman-web makemigrations --merge"

(the -s /bin/bash is because the list account has a /usr/sbin/nologin shell in 
/etc/passwd)

Also note that Debian has a wrapper for mailman commands (but not mailman-web
commands), for example:

root@ds-services-mailman:~# mailman-wrapper version
GNU Mailman 3.3.8 (Tom Sawyer)

This wrapper, when run from root (sudo mailman-wrapper or just mailman-wrapper
under the root user) changes the user to the list user:

   root@ds-services-mailman:~# cat $(which mailman-wrapper)
   #!/bin/sh

   su -s /bin/sh -c "mailman $*" list

Not very different from my su above.
_______________________________________________
Mailman-users mailing list -- mailman-users@mailman3.org
To unsubscribe send an email to mailman-users-le...@mailman3.org
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
Archived at: 
https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/J5CWBN2UVXBAXIJBHSZY5VJOBSNZOXEV/

This message sent to arch...@mail-archive.com

Reply via email to