Versions in this module Expand all Collapse all v0 v0.10.0 Oct 19, 2026 v0.0.0 Oct 16, 2026 Changes in this version + const BootContainerPath + const ContainerGenerationLink + const ContainerProfileLink + const DefaultBuildCPUs + const DefaultRegistry + const DefaultSquidImage + const DefaultThinStoreVolume + const NixCoreImage + const NixDFReportScript + const NixGCRootReportScript + const NixHealthProbeScript + const ProfilePath + const SafeNixGCScript + const ThinEntrypointSentinel + var ErrBuilderRunning = errors.New("builder already running") + var ErrDockerDaemonUnreachable = errors.New("Docker is not running. Please start Docker and retry") + var Modules []string + var PerCellImage bool + var Registry = DefaultRegistry + var Stack = "base" + func BootGroupCount(cellCfg cfg.CellConfig) int + func BuildArgv(spec RunSpec, fs FS, lookPath func(string) (string, error)) []string + func BuildCleanupPrompt(closures []LiveClosure) string + func BuildCleanupScript(closures []LiveClosure) string + func BuildExecArgv(spec ExecSpec) []string + func BuildLabel(prefix, stack string, explicit bool) string + func BuildPrunePrompt(opts PruneOpts) string + func BuilderContainerState(ctx context.Context, name string) (exists, running bool) + func BuilderOrphanedByCancel(runErr, ctxErr error) bool + func CleanupOrphanedProxies(ctx context.Context, skipCellName string) error + func ClosureAliveArgv(volume, image string) []string + func ClosureDeadWarning(alive bool) (warning string, dead bool) + func CollectRunningContainers(ctx context.Context) ([]string, error) + func CollectVolumeMounts(ctx context.Context) map[string][]string + func ConfirmDestructive(out io.Writer, in io.Reader, skipYes bool, isTTY bool, warning string) bool + func ConfirmProceed(out io.Writer, in io.Reader, isTTY bool, warning string) bool + func ConsumeContainerEventsPanel(events <-chan ContainerEvent, panel ux.BootView) bool + func ContainerLabel(ctx context.Context, name, key string) string + func ContainerRunning(ctx context.Context, name string) bool + func DebugArgv(argv []string) string + func DetectArch() string + func DockerBindProbeArgv(image, volume, source, marker string) []string + func DockerDaemonReachable(ctx context.Context) error + func DockerHostPath(p string) string + func DockerPlatform(arch string) string + func DockerResolveContainerLink(ctx context.Context, container, link string) (string, error) + func DockerRunningDevcellContainers(ctx context.Context) ([]string, error) + func DockerVolumeDebug(ctx context.Context, volume string) string + func EnsureIsolatedNetwork(ctx context.Context, name string, isolateGateway bool) error + func EnsureNetwork(ctx context.Context) error + func EnsureProxySidecar(ctx context.Context, opts ProxySidecarOpts) error + func EnsureVolumeShell(ctx context.Context, volumeName, coreImage string) error + func EnsureVolumeShellArgv(volumeName, coreImage string) []string + func FlakeNixImage() string + func FormatJSON(snap DFSnapshot, opts FormatOpts, w io.Writer) error + func FormatNixStoreSection(r NixStoreReport, w io.Writer) + func FormatTable(snap DFSnapshot, opts FormatOpts, w io.Writer) error + func FormatTableWithVM(snap DFSnapshot, opts FormatOpts, vm VMDiskInfo, containers []string, ...) error + func GenerateACLFiles(allow, block []string) map[string]string + func GenerateSquidConf(mode string) string + func HydrateNixCache(ctx context.Context, volumeName, registry, arch string) error + func ImageExists(ctx context.Context, tag string) bool + func ImageExistsForPlatform(ctx context.Context, tag, platform string) bool + func ImageLabel(ctx context.Context, image, key string) string + func ImageVersions(ctx context.Context) (base, user string) + func InternalNetworkName(cellName string) string + func KVMProbeArgv() []string + func LocalImageIDFor(ctx context.Context, tag string) (string, error) + func LocalImageSize(ctx context.Context, tag string) int64 + func NixCacheDockerArch(arch string) string + func NixCacheImageRef(registry, arch string) string + func NixHealthProbeArgv(volume string) []string + func ParseClosureAliveResult(stdout string, err error) (resolvedPath string, alive bool) + func ParseSize(s string) (int64, error) + func PickImageTag(impure bool) string + func PickImageTagThin() string + func PrepareWireguard(cellHome string, cellCfg cfg.CellConfig) error + func ProbeDockerBind(ctx context.Context, image, volume, source, marker string) (string, error) + func ProbeKVM(ctx context.Context) bool + func ProjectNixpkgsRev(baseDir string) (string, error) + func ProxyConfDir(cellHome, cellName string) string + func ProxySidecarName(cellName string) string + func PullImageForPlatform(ctx context.Context, tag, platform string, verbose bool) error + func ReclaimBuilderSlot(name string, exists, running bool) (remove bool, err error) + func RemoveNetwork(ctx context.Context, name string) error + func RemoveOrphanedContainer(ctx context.Context, name string) error + func RemoveProxySidecar(ctx context.Context, name string) error + func ResolveBuildTag(custom, derived string) string + func ResolveTrustFlake(baseDir, cellHome string) bool + func RunCleanup(a RunCleanupArgs) error + func RunDF(a RunDFArgs) error + func RunPrune(a RunPruneArgs) error + func ShouldHydrateFromCache(hydrated bool, getenv func(string) string) bool + func StaleCellWarning(projectRev string, h NixStoreHealth) (string, bool) + func StampRootsScript(closures []LiveClosure) string + func ThinBuildArgvFull(...) []string + func ThinBuildArgvWithPackages(...) []string + func ThinBuilderContainerName(appName string) string + func ThinStoreVolume() string + func UpdateFlakeLock(ctx context.Context, configDir string, lockOnly bool, verbose bool, ...) error + func UserImageTag() string + func UserImageTagPure() string + func UserImageTagThin() string + func ValidateProxyCompatibility(c cfg.CellConfig) error + func VolumeContains(ctx context.Context, volumeName, sentinelPath string) bool + func VolumeContainsArgv(volumeName, sentinelPath string) []string + func VolumeExists(ctx context.Context, name string) bool + func VolumeHydrated(volumeName, sentinelPath string, exists func(string) bool, ...) bool + func WriteThinBuildContext(w io.Writer, buildDir string) error + type BuildLimits struct + CPUs string + Cores int + MaxJobs int + Memory string + func ResolveBuildLimits() BuildLimits + type ContainerEvent struct + Msg string + Scope string + Service string + Status string + TS time.Time + type ContainerLogWatcher struct + func NewContainerLogWatcher(ctx context.Context, container string, since time.Time) *ContainerLogWatcher + func (w *ContainerLogWatcher) Close() + func (w *ContainerLogWatcher) Events() <-chan ContainerEvent + type DFCache struct + CreatedSince string + Description string + ID string + InUse bool + Shared bool + SizeBytes int64 + UsageCount int + type DFCollector interface + CollectSystemDF func(ctx context.Context) ([]byte, error) + type DFContainer struct + ID string + ImageRef string + Names string + SizeBytes int64 + State string + type DFImage struct + Containers int + CreatedSince string + ID string + Repository string + SharedBytes int64 + SizeBytes int64 + Tag string + UniqueBytes int64 + type DFOpts struct + JSON bool + Kinds []EntryKind + TopN int + type DFSnapshot struct + BuildCache []DFCache + Containers []DFContainer + Images []DFImage + Volumes []DFVolume + func ParseSystemDF(raw []byte) (DFSnapshot, error) + type DFVolume struct + Links int + Name string + SizeBytes int64 + type DockerCapacity struct + MemBytes int64 + NCPU int + type DockerDebugInfo struct + Architecture string + CPUs int + Context string + DockerHostEnv string + Endpoint string + MemoryBytes int64 + Name string + OperatingOS string + RootDir string + Runtime string + ServerVersion string + Socket string + SocketTarget string + func CollectDockerDebugInfo(ctx context.Context) (DockerDebugInfo, error) + type Engine struct + func (Engine) Build(ctx context.Context, opts engine.BuildOpts) error + func (Engine) Init(_ context.Context, opts engine.InitOpts) error + func (Engine) Run(ctx context.Context, opts engine.RunOpts) error + type EntryKind string + const EntryKindCache + const EntryKindContainer + const EntryKindImage + const EntryKindVolume + type ExecCollector struct + func (ExecCollector) CollectSystemDF(ctx context.Context) ([]byte, error) + type ExecSpec struct + Args []string + Binary string + ContainerName string + Env map[string]string + TTY bool + User string + type FS interface + Stat func(path string) error + var OsFS FS = FSFunc(func(path string) error { ... }) + type FSFunc func(string) error + func (f FSFunc) Stat(path string) error + type FormatOpts struct + Kinds []EntryKind + TopN int + type ImageMetadata struct + BaseImage string + BuildDate string + GitCommit string + Modules []string + Packages int + Stack string + func ImageMetadataFromContainer(ctx context.Context) ImageMetadata + func ParseImageMetadata(data []byte) ImageMetadata + type LiveClosure struct + Container string + GenerationPath string + ProfilePath string + func CollectLiveClosures(ps func() ([]string, error), ...) ([]LiveClosure, error) + type NixRootEntry struct + Name string + Stale bool + type NixRootMeta struct + Hash string + Nixpkgs string + Project string + Stack string + type NixStoreHealth struct + DistinctRevs int + Generations int + NewestProjects int + NewestRev string + OrphanedGenerations int + ProfileHashes int + StaleRoots int + TotalRoots int + func ParseNixStoreHealth(out string) (NixStoreHealth, error) + func (h NixStoreHealth) Summary() (tag, detail string, warn bool) + type NixStoreReport struct + Health NixStoreHealth + Metas []NixRootMeta + Roots []NixRootEntry + Volume string + func CollectNixStore(ctx context.Context) (NixStoreReport, bool) + func ParseNixStoreReport(volume, out string) (NixStoreReport, error) + type ProxySidecarOpts struct + CellID string + CellName string + EgressNet string + InternalNet string + Proxy cfg.NetworkProxySection + SquidImage string + WorkspaceHome string + WorkspaceName string + type PruneOpts struct + Force bool + GOOS string + HomeDir string + LinuxBuilderHost string + LiveClosures []LiveClosure + NixOS bool + Pure bool + Rootless bool + type PruneStep struct + Argv []string + DryRun bool + Func func(ctx context.Context) error + IgnoreError bool + func BuildCleanupSteps(closures []LiveClosure) []PruneStep + func BuildDockerPruneSteps(opts PruneOpts) []PruneStep + func BuildNixPruneSteps(opts PruneOpts) []PruneStep + type RankedEntry struct + ID string + Kind EntryKind + Label string + PinCount int + ReclaimBytes int64 + SizeBytes int64 + func RankEntries(snap DFSnapshot, topN int) []RankedEntry + type RunCleanupArgs struct + Closures []LiveClosure + Exec func(step PruneStep) error + In io.Reader + IsTTY bool + Out io.Writer + SkipYes bool + type RunDFArgs struct + Collector DFCollector + Ctx context.Context + Opts DFOpts + Out io.Writer + type RunPruneArgs struct + Exec func(step PruneStep) error + In io.Reader + IsTTY bool + Opts PruneOpts + Out io.Writer + SkipYes bool + type RunSpec struct + Binary string + BootDir string + CellCfg cfg.CellConfig + Config config.Config + Debug bool + DefaultFlags []string + Detach bool + ExtraEnv map[string]string + Getenv func(string) string + GitConfig func(string) string + Image string + InheritEnv []string + KVMAutoDetected bool + Lifecycle string + NixDaemon bool + NoPorts bool + NoSecrets bool + Policy cfg.Policy + ProxyEnabled bool + TTY bool + ThinImage bool + TrustFlake bool + UserArgs []string + type VMDiskInfo struct + AvailBytes int64 + TotalBytes int64 + UsedBytes int64 + func CollectVMDisk(ctx context.Context) (VMDiskInfo, error)