Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions static/etc/system-image/writable-paths
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@
# snap data
/var/snap auto persistent transition none
# generic
/media none temporary none defaults
/mnt none temporary none defaults
/media none temporary none mode=1777,strictatime,nosuid,nodev
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need mode=1777 for /mnt and /media ? Those are not really dirs that have the same semantic as /tmp, they are more dirs with a similar semantic as /run AIUI. Or is there soemthing I'm missing here?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without this change, when I run stat on /mnt and /media it actually shows mode 1777 already, so I think that is the default mode. This just shows that more explicitly. So we can remove it I guess, I do not have a strong opinion either way.

/mnt none temporary none mode=1777,strictatime,nosuid,nodev
/root auto persistent transition none
/tmp none temporary none defaults
/tmp none temporary none mode=1777,strictatime,nosuid,nodev
/var/tmp auto persistent transition none
# etc related
/etc/writable auto persistent transition none
Expand Down
6 changes: 6 additions & 0 deletions tests/spread/basic/task.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,9 @@ execute: |
# Verify system services are running
execute_remote systemctl -q is-active snapd
execute_remote snap change 1

# Check tmpfs mount options are as expected
execute_remote grep -e 'tmpfs /tmp .*nosuid,nodev.*' /proc/mounts
execute_remote grep -e 'tmpfs /media .*nosuid,nodev.*' /proc/mounts
execute_remote grep -e 'tmpfs /mnt .*nosuid,nodev.*' /proc/mounts
execute_remote grep -e 'tmpfs /var/lib/sudo .*nosuid,nodev,mode=700.*' /proc/mounts