hst: improve doc comments
All checks were successful
Test / Create distribution (push) Successful in 1m3s
Test / Sandbox (push) Successful in 2m40s
Test / Hakurei (push) Successful in 3m40s
Test / ShareFS (push) Successful in 3m47s
Test / Sandbox (race detector) (push) Successful in 5m3s
Test / Hakurei (race detector) (push) Successful in 5m58s
Test / Flake checks (push) Successful in 1m26s
All checks were successful
Test / Create distribution (push) Successful in 1m3s
Test / Sandbox (push) Successful in 2m40s
Test / Hakurei (push) Successful in 3m40s
Test / ShareFS (push) Successful in 3m47s
Test / Sandbox (race detector) (push) Successful in 5m3s
Test / Hakurei (race detector) (push) Successful in 5m58s
Test / Flake checks (push) Successful in 1m26s
These now read a lot better both in source and on pkgsite. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
15
hst/fs.go
15
hst/fs.go
@@ -24,7 +24,8 @@ type FilesystemConfig interface {
|
||||
fmt.Stringer
|
||||
}
|
||||
|
||||
// The Ops interface enables [FilesystemConfig] to queue container ops without depending on the container package.
|
||||
// The Ops interface enables [FilesystemConfig] to queue container ops without
|
||||
// depending on the container package.
|
||||
type Ops interface {
|
||||
// Tmpfs appends an op that mounts tmpfs on a container path.
|
||||
Tmpfs(target *check.Absolute, size int, perm os.FileMode) Ops
|
||||
@@ -41,12 +42,15 @@ type Ops interface {
|
||||
// Link appends an op that creates a symlink in the container filesystem.
|
||||
Link(target *check.Absolute, linkName string, dereference bool) Ops
|
||||
|
||||
// Root appends an op that expands a directory into a toplevel bind mount mirror on container root.
|
||||
// Root appends an op that expands a directory into a toplevel bind mount
|
||||
// mirror on container root.
|
||||
Root(host *check.Absolute, flags int) Ops
|
||||
// Etc appends an op that expands host /etc into a toplevel symlink mirror with /etc semantics.
|
||||
// Etc appends an op that expands host /etc into a toplevel symlink mirror
|
||||
// with /etc semantics.
|
||||
Etc(host *check.Absolute, prefix string) Ops
|
||||
|
||||
// Daemon appends an op that starts a daemon in the container and blocks until target appears.
|
||||
// Daemon appends an op that starts a daemon in the container and blocks
|
||||
// until target appears.
|
||||
Daemon(target, path *check.Absolute, args ...string) Ops
|
||||
}
|
||||
|
||||
@@ -61,7 +65,8 @@ type ApplyState struct {
|
||||
// ErrFSNull is returned by [json] on encountering a null [FilesystemConfig] value.
|
||||
var ErrFSNull = errors.New("unexpected null in mount point")
|
||||
|
||||
// FSTypeError is returned when [ContainerConfig.Filesystem] contains an entry with invalid type.
|
||||
// FSTypeError is returned when [ContainerConfig.Filesystem] contains an entry
|
||||
// with invalid type.
|
||||
type FSTypeError string
|
||||
|
||||
func (f FSTypeError) Error() string { return fmt.Sprintf("invalid filesystem type %q", string(f)) }
|
||||
|
||||
Reference in New Issue
Block a user