-
-
Notifications
You must be signed in to change notification settings - Fork 49
Create $XDG_RUNTIME_DIR in /run/user/{uid} #203
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
Conversation
|
I couldn't find a justification for using |
5199214 to
ce4086e
Compare
|
I think it should be changed, yeah, but some other existing assumptions might need to be fixed, e.g. muvm/crates/muvm/src/guest/mount.rs Line 35 in 5b35e56
The other thing I could think of is, maybe this ( |
|
AIUI the part where I changed is in the user initialization part, which happens after FEX init, so |
|
Hmm... Actually, if we're changing this, why are we not just using the typical Anyway, relevant part from the spec:
|
|
Oh, good idea. I'll change it to |
ce4086e to
183f414
Compare
|
The directory and permissions now looks like this $ namei -l $XDG_RUNTIME_DIR
f: /run/user/1000
drwxr-xr-x root root /
drwxrwxrwt root root run
drwxr-xr-x root root user
drwx------ dram users 1000 |
6c2e2ee to
c7a6520
Compare
IIRC it's in |
|
Please fix the clippy issue. Otherwise LGTM, thanks! |
Using tempfile::Builder::tempdir() defaults to creating this directory
in /tmp, which is shared with the host and often somewhat persistent.
This causes one extra directory to be created in the host /tmp every
time muvm runs.
Since we mount /run as a tmpfs now in the guest now, just create
$XDG_RUNTIME_DIR in /run/user/{uid}, a common default. Specifically:
- Create /run/user as 0o755 (rwxr-xr-x) owned by root:root
- Create /run/user/{uid} as 0o700 (rwx------) owned by uid:gid
Signed-off-by: Vivian Wang <dramforever@live.com>
c7a6520 to
c421925
Compare
|
Clippy should be happy now |
Using tempfile::Builder::tempdir() defaults to creating this directory in /tmp, which is shared with the host and often somewhat persistent. This causes one extra directory to be created in the host /tmp every time muvm runs.
Since we mount /run as a tmpfs now in the guest now, just create $XDG_RUNTIME_DIR in /run/user/{uid}, a common default. Specifically: