-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Sharing files and folders
The /etc/crouton/shares
file in your chroot defines directories to map into the chroot from the host.
Order is important: be sure to mount directories before you mount subdirectories of those mounts.
Outside the chroot, the only directories that can be mapped are subdirectories of the following locations:
- downloads: ~/Downloads
- shared: /mnt/stateful_partition/crouton/shared
- encrypted: ~/crouton/shared
Inside the chroot, any absolute or user-relative path (~/x or ~user/x) is OK. Using a path that already exists in the chroot will result in that path being overmounted and difficult to access.
Syntax is as follows:
HOSTDIR CHROOTDIR [OPTIONS]
Directory names can have spaces (if quoted), but no quote characters or relative path elements (..'s).
Options can be any fstab-like options to mount. If unspecified, "exec" is assumed.
Share a home directory encrypted by the current user's unsynced profile
encrypted/home ~
Share an unencrypted directory between chroots.
shared/home ~/Share
Absolute directories on the chroot side work too
shared/bin /usr/local/bin exec,suid
Share a noexec path that has spaces, and a specific user home directory
"encrypted/stupid example" "~omg/Why are you even doing this?" noexec
WARNING: dont delete things unless you want to delete them.
Most chrome-apps don't allow access to the home-folder (only USB and Downloads-folder) The simplest workaround is:
- buy a tiny usb stick and plug it into your chromebook:
- create an empty directory on it, called 'crouton'
- then enter your crouton chroot, and run this command:
mount --bind / /media/removable/YOURUSBDISK/crouton
TODO automation using fstab