Open onli opened 8 months ago
Might this be a systemd issue? I used the provided systemd service file.
Yes, it's a systemd issue. When removing these restrictions, portier works now with sendmail:
TemporaryFileSystem=/run
RemoveIPC=yes
CapabilityBoundingSet=
PrivateTmp=yes
PrivateDevices=yes
PrivateUsers=yes
ProtectSystem=strict
ProtectHome=yes
ProtectKernelTunables=yes
ProtectKernelModules=yes
ProtectControlGroups=yes
RestrictAddressFamilies=AF_INET AF_INET6
LockPersonality=yes
NoNewPrivileges=yes
MemoryDenyWriteExecute=yes
RestrictRealtime=yes
RestrictNamespaces=yes
SystemCallFilter=@system-service
SystemCallErrorNumber=EPERM
We should pinpoint and document which restriction exactly blocks sendmail from working
On a linux system, I have a working sendmail system. It relays messages via sendgrid, and this works:
This works under
root
, and it works underbroker
. The mail arrives in my inbox.Now I enable portier to use sendmail, by uncomenting this line in the config.toml:
The results vary depending under which user the broker now runs. Under broker and dynamic user, I get this:
(note though that the same user was able send mails on the terminal.)
Under root I get this:
Might this be a systemd issue? I used the provided systemd service file.