How to add the Kanata service, which runs as a systemd dynamic user, to a group?

source code in nixpkgs

How do I add this user to a specific group in my configuration?

systemd.services."kanata-${name}".serviceConfig.SupplementaryGroups = [ "somegroup" ];

That said, why?

2 Likes

There is a bug/feature in Systemd which renders SupplementaryGroups not working with dynamic users :frowning:

The bug report is from 2018 and looks unconfirmed. I am using SupplementaryGroups a lot, e.g. with the acme group, and I think we would be on top of the systemd people if that didn’t work.