Shared directory with setgid not working as expected
0
votes
1
answer
246
views
I have a group of developers who want to share the same directory. I created a new group with these developers and created a directory for them. On that directory, I set the group to the group I created and set the setgid bit.
And that all works great... files and directories that are *created* inside this shared directory have the right permissions. But the developers use an application that is doing something that results in unexpected permissions. Instead of files and directories being created with the group of the shared directory, they have the group of the user. And on directories, the setgid bit isn't set.
My *guess* as to what is happening is the application is creating a directory hierarchy someplace else (such as /tmp) and when it's done, it's *moving* that to the shared directory. If it isn't that it's something like that. My solution so far is to manually adjust the permissions; I search for files and directories that don't have the right permissions with *find* and then pipe that list into *xargs*. And since this is a constant problem, I'll probably use *super* to give the developers a way to fix up the permissions themselves.
Is there a better solution?
Asked by John Passaniti
(1 rep)
Oct 12, 2022, 04:22 PM
Last activity: Oct 12, 2022, 06:45 PM
Last activity: Oct 12, 2022, 06:45 PM