docker

package
v0.4.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(cfg *config.Config, project string, force bool) (string, error)

Build builds a Docker image from the given config. It returns the image tag.

func Exec

func Exec(project, workdir string) error

Exec attaches to an existing container by namespace prefix.

func ImageExists

func ImageExists(tag string) bool

ImageExists checks if a Docker image with the given tag exists locally.

func ImageTag

func ImageTag(project, agentName, dockerfile string) string

ImageTag computes the image tag for a project from the rendered Dockerfile and embedded dotfile contents.

func RenderDockerfile

func RenderDockerfile(cfg *config.Config) (string, error)

RenderDockerfile generates the full Dockerfile content from a config.

func Run

func Run(cfg *config.Config, project, workdir, imageTag string, extraArgs []string) error

Run launches a new Docker container.

Types

type RenderData

type RenderData struct {
	ToolInstructions []string // rendered tool Dockerfile lines
	RootSteps        []string // raw root-level Dockerfile steps (pre-tools)
	CustomSteps      []string // raw custom Dockerfile steps
	AgentInstall     string   // agent install RUN command
	AgentExtraEnv    []string // agent extra ENV lines ("KEY=VALUE")
	Entrypoint       string   // JSON array for ENTRYPOINT
	ToolEnvVars      []string // sorted "KEY=VALUE" lines from tools
	ToolPath         string   // pre-computed PATH value
	NpmConfig        string   // npm .npmrc setup (empty if no nodejs)
}

RenderData holds all values injected into the Dockerfile template.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL