Open very-amused opened 2 years ago
The try/finally clause that was requested has been added. I don't see the need for a feature flag to enable this behavior, I believe making sockets group-writable is a sane default.
I don't see the need for a feature flag to enable this behavior, I believe making sockets group-writable is a sane default.
While I agree with you, this code removes the ability of users to control the umask themselves for this socket, so it's worth thinking about.
Apologies for the lack of updates for a while. I just implemented the config option mpd/socket_permissions
with a default value of 775
. The behavior of making Unix sockets group-writable by default is retained, while allowing users to control the umask themselves if desired.
When Mopidy is run as a system service under the
mopidy
user, Unix sockets are currently created with a umask of022
, which makes other users unable to connect due to having no write permission. This PR ensures Unix sockets are created with a umask of002
, making them writable to users in themopidy
group and thus usable to users added to this group.