The directory /var/run/atheme is required to store the PID file but the directory is not created by the ebuild. Reproducible: Always Steps to Reproduce: 1. emerge atheme-services 2. ls -l /var/run Actual Results: no dir "atheme" Expected Results: dir "atheme" exists and is writable by the atheme-services group (or user)
Why would the ebuild create directories under '/var/run' as part of merging? '/var/run' is a symlink to '/run' which itself is a 'tmpfs' filesystem which means its contents are destroyed on reboot. If this directory was created at merge time then it would be gone after a reboot. The directory is created when the service is launched in its init.d script as part of the 'start_pre' function[1]. Starting the service creates the directory and works as expected on my end, and should for others as well. [1] https://github.com/gentoo/gentoo/blob/master/net-irc/atheme-services/files/atheme-services.initd
You're right. I see now the issue is systemd-specific. I've added the RuntimeDirectory= directive to the unit file attached to https://bugs.gentoo.org/895470 which matches the behavior you describe. Closing this issue.