sudo -u gitea sendmail -t me@my.mail.domain … # works - no postdrop message
sudo -u gitea touch /var/spool/postfix/maildrop/bla123 # works after adding user gitea to group postdrop
so sendmail is there and accessible by user gitea.
I suspect this is a permission problem, but I have no clue how to nail it down.
If You need more info, please ask.
This is an aside to the issue, but the the mailer settings were tweaked slightly in 1.18.x to simplify things, but it looks like the docs were not updated. You should use PROTOCOL = sendmail instead of MAILER_TYPE = sendmail since MAILER_TYPE is deprecated and will eventually be removed. It won’t fix your problem though.
How are you running Gitea? If it’s a systemd service, can you post the contents of gitea.service?
I think issue is likely caused by some of the protection directives in gitea.service. Can you test running Gitea with a minimal service file like this? If this fixes issue, I would reintroduce the other directives one-by-one until issue is triggered to find out what directive caused issue.
[Unit]
Description=Gitea (Git with a cup of tea)
After=syslog.target
After=network.target
After=mysqld.service
After=postgresql.service
After=memcached.service
After=redis.service
[Service]
User=gitea
Group=gitea
Type=simple
WorkingDirectory=~
Environment=USER=gitea HOME=/var/lib/gitea GITEA_WORK_DIR=/var/lib/gitea
ExecStart=/usr/bin/gitea web -c /etc/gitea/app.ini
[Install]
WantedBy=multi-user.target