Allow different users in the same group to share a session. #3406
+85
−12
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I understand from the CONTRIBUTING.md document that the project doesn't have the capacity to field random feature PRs while it works on its roadmap. And this random feature PR is a sketch that doesn't even have tests!
...but, @fzakaria encouraged me to open it to gauge interest. No worries if the answer is everyone's too busy to review or merge, but I'm totally willing to iterate on it -- I have a sequence of ideas about how this could be evolved into a more secure method of collaboration -- and, you know, add tests too.
Anyway, here's what's in the commit:
Adds a
ZELLIJ_SOCKET_GROUP
environment variable that specifies the group by name that should own the Zellij sockets and socket directory.When this environment variable is set for a Zellij server, it will chown the Zellij socket directory and session socket to be owned by the named group with group read and execute (list) permissions set.
When this environment variable is set for a Zellij client, it will check that Zellij socket directory is owned by the expected group.
Example usage:
As user
foo
:As user
bar
: