Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NixOS VMs: feature request: allow configuring the owner and group of the 9P shares #95837

Open
8573 opened this issue Aug 20, 2020 · 1 comment
Labels
2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 6.topic: nixos

Comments

@8573
Copy link
Contributor

8573 commented Aug 20, 2020

In a NixOS virtual machine (the sort started with run-<hostname>-vm), there are two directories, /tmp/shared and /tmp/xchg, intended for exchanging data with the host via 9P. The latter directory corresponds on the host to a temporary directory owned by the user running the VM, and the former directory, by default, corresponds to the same. In the guest, however, these directories are owned by root:root. By default, the temporary directory on the host that corresponds to these is created with the host user's default umask, and the 9P-shared directories in the guest inherit its file mode, so, for me with umask 077, the directories are accessible only to root.

Currently, the only way for the host to make the 9P shares accessible to non-root users in the guest would seem to be making the corresponding directory on the host world-accessible, as there doesn't seem to be a means to control (from the VM's NixOS configuration or otherwise from the host) who owns the 9P shares in the guest. I would like to suggest that such a means could be useful.

(Searching for previous issues matching "vm 9p root" didn't seem to show any existing tickets for this; my own #21490 seemed the least irrelevant.)

@stale
Copy link

stale bot commented Feb 18, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Feb 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 6.topic: nixos
Projects
None yet
Development

No branches or pull requests

2 participants