Documentation
¶
Overview ¶
Package probe checks at startup which volume modes a host accepts. The result is given to every microvm provider, which advertises it as the capabilities volume-overlay and volume-full.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Probes ¶
type Probes struct {
// Reflink checks that FICLONE works in the state directory.
Reflink func(ctx context.Context) error
// MkfsErofs checks that the pinned mkfs.erofs is present and reports
// the version of the base profile.
MkfsErofs func(ctx context.Context) error
// MkfsExt4 checks that mkfs.ext4 is present.
MkfsExt4 func(ctx context.Context) error
// Snapshotter checks that containerd loaded the volume snapshotter.
Snapshotter func(ctx context.Context) error
}
Probes are the checks of one host. Each returns nil when the host passes. volume-overlay needs Reflink, MkfsErofs and MkfsExt4. volume-full needs Snapshotter.
func Host ¶
func Host(stateDir, mkfsErofsPath string, cfg *containerd.Config, client containerd.Client) Probes
Host returns the probes of this host. The reflink probe runs in stateDir and creates it when needed. The snapshotter probe asks containerd through client about the snapshotter named in cfg.
Click to show internal directories.
Click to hide internal directories.