diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-10-12 05:03:14 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-10-12 05:03:14 +0900 |
| commit | 8a91234cb4d8cbf6e1d5b909bc11f630d78a93e5 (patch) | |
| tree | 2a8997564266ff2c2815d67ba5261fbd9e29ed05 /hst/fsbind.go | |
| parent | db7051a36814a5c9e02e22c2e8d1df42c5f4b8f0 (diff) | |
hst: reword and improve doc comments
This corrects minor mistakes in doc comments and adds them for undocumented constants.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'hst/fsbind.go')
| -rw-r--r-- | hst/fsbind.go | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/hst/fsbind.go b/hst/fsbind.go index f94e467b..bb1fc036 100644 --- a/hst/fsbind.go +++ b/hst/fsbind.go @@ -16,22 +16,23 @@ const FilesystemBind = "bind" // FSBind represents a host to container bind mount. type FSBind struct { - // mount point in container, same as Source if empty + // Pathname in the container mount namespace. Same as Source if nil. Target *check.Absolute `json:"dst,omitempty"` - // host filesystem path to make available to the container + // Pathname in the init mount namespace. Must not be nil. Source *check.Absolute `json:"src"` - // do not mount Target read-only + // Do not remount Target read-only. + // This has no effect if Source is mounted read-only in the init mount namespace. Write bool `json:"write,omitempty"` - // do not disable device files on Target, implies Write + // Allow access to devices (special files) on Target, implies Write. Device bool `json:"dev,omitempty"` - // create Source as a directory if it does not exist + // Create Source as a directory in the init mount namespace if it does not exist. Ensure bool `json:"ensure,omitempty"` - // skip this mount point if Source does not exist + // Silently skip this mount point if Source does not exist in the init mount namespace. Optional bool `json:"optional,omitempty"` - // enable special behaviour: - // for autoroot, Target must be set to [fhs.AbsRoot]; - // for autoetc, Target must be set to [fhs.AbsEtc] + /* Enable special behaviour: + For autoroot: Target must be [fhs.Root]. + For autoetc: Target must be [fhs.Etc]. */ Special bool `json:"special,omitempty"` } |
