7bc96aec |
package mount
import ( |
069fdc8a |
"golang.org/x/sys/unix" |
7bc96aec |
)
|
3754fdd7 |
const ( |
9a98556c |
// RDONLY will mount the file system read-only. |
069fdc8a |
RDONLY = unix.MS_RDONLY |
9a98556c |
// NOSUID will not allow set-user-identifier or set-group-identifier bits to
// take effect. |
069fdc8a |
NOSUID = unix.MS_NOSUID |
9a98556c |
// NODEV will not interpret character or block special devices on the file
// system. |
069fdc8a |
NODEV = unix.MS_NODEV |
9a98556c |
// NOEXEC will not allow execution of any binaries on the mounted file system. |
069fdc8a |
NOEXEC = unix.MS_NOEXEC |
9a98556c |
// SYNCHRONOUS will allow I/O to the file system to be done synchronously. |
069fdc8a |
SYNCHRONOUS = unix.MS_SYNCHRONOUS |
9a98556c |
// DIRSYNC will force all directory updates within the file system to be done |
927b334e |
// synchronously. This affects the following system calls: create, link, |
9a98556c |
// unlink, symlink, mkdir, rmdir, mknod and rename. |
069fdc8a |
DIRSYNC = unix.MS_DIRSYNC |
9a98556c |
// REMOUNT will attempt to remount an already-mounted file system. This is
// commonly used to change the mount flags for a file system, especially to
// make a readonly file system writeable. It does not change device or mount
// point. |
069fdc8a |
REMOUNT = unix.MS_REMOUNT |
9a98556c |
// MANDLOCK will force mandatory locks on a filesystem. |
069fdc8a |
MANDLOCK = unix.MS_MANDLOCK |
9a98556c |
// NOATIME will not update the file access time when reading from a file. |
069fdc8a |
NOATIME = unix.MS_NOATIME |
9a98556c |
// NODIRATIME will not update the directory access time. |
069fdc8a |
NODIRATIME = unix.MS_NODIRATIME |
9a98556c |
// BIND remounts a subtree somewhere else. |
069fdc8a |
BIND = unix.MS_BIND |
9a98556c |
// RBIND remounts a subtree and all possible submounts somewhere else. |
069fdc8a |
RBIND = unix.MS_BIND | unix.MS_REC |
9a98556c |
// UNBINDABLE creates a mount which cannot be cloned through a bind operation. |
069fdc8a |
UNBINDABLE = unix.MS_UNBINDABLE |
9a98556c |
// RUNBINDABLE marks the entire mount tree as UNBINDABLE. |
069fdc8a |
RUNBINDABLE = unix.MS_UNBINDABLE | unix.MS_REC |
9a98556c |
// PRIVATE creates a mount which carries no propagation abilities. |
069fdc8a |
PRIVATE = unix.MS_PRIVATE |
9a98556c |
// RPRIVATE marks the entire mount tree as PRIVATE. |
069fdc8a |
RPRIVATE = unix.MS_PRIVATE | unix.MS_REC |
9a98556c |
// SLAVE creates a mount which receives propagation from its master, but not
// vice versa. |
069fdc8a |
SLAVE = unix.MS_SLAVE |
9a98556c |
// RSLAVE marks the entire mount tree as SLAVE. |
069fdc8a |
RSLAVE = unix.MS_SLAVE | unix.MS_REC |
9a98556c |
// SHARED creates a mount which provides the ability to create mirrors of
// that mount such that mounts and unmounts within any of the mirrors
// propagate to the other mirrors. |
069fdc8a |
SHARED = unix.MS_SHARED |
9a98556c |
// RSHARED marks the entire mount tree as SHARED. |
069fdc8a |
RSHARED = unix.MS_SHARED | unix.MS_REC |
9a98556c |
// RELATIME updates inode access times relative to modify or change time. |
069fdc8a |
RELATIME = unix.MS_RELATIME |
9a98556c |
// STRICTATIME allows to explicitly request full atime updates. This makes
// it possible for the kernel to default to relatime or noatime but still
// allow userspace to override it. |
069fdc8a |
STRICTATIME = unix.MS_STRICTATIME |
acbfe6bc |
|
069fdc8a |
mntDetach = unix.MNT_DETACH |
3754fdd7 |
) |