graft

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Engine

type Engine struct {
	PullStrategy PullStrategy
}

Engine handles image pulling

func (*Engine) HandleImage

func (e *Engine) HandleImage(service, image string) error

HandleImage handles image pulling based on strategy

func (*Engine) ImageExists

func (e *Engine) ImageExists(image string) bool

ImageExists checks if an image exists locally. Returns false if the image is not found (exit code 125) or if podman encounters an unexpected error. Non-125 errors are logged as warnings since they may indicate a podman installation problem.

func (*Engine) PullImage

func (e *Engine) PullImage(image string) error

PullImage pulls an image from a registry

type Grafter

type Grafter struct {
	ProjectName    string
	SecretsDir     string
	DryRun         bool
	SELinuxEnabled bool
}

Grafter post-processes quadlet files to handle compose fields that podlet does not support or supports with known flaws.

func (*Grafter) Process

func (g *Grafter) Process(
	files map[string]string,
	services map[string]preprocess.ServiceImageSpec,
	secretDefs map[string]preprocess.SecretDef,
	serviceSecretRefs preprocess.ServiceSecretRefs,
) map[string]string

Process post-processes quadlet file contents generated by the cooker.

type ImageResult

type ImageResult struct {
	Service string
	Image   string
	Action  string // "pulled", "found", "skipped"
	Error   error
}

ImageResult represents the outcome of handling an image

type PullStrategy

type PullStrategy string

PullStrategy defines how images should be pulled

const (
	// PullAlways always pulls images
	PullAlways PullStrategy = "always"
	// PullMissing pulls only if image not found locally
	PullMissing PullStrategy = "missing"
	// PullNever never pulls images
	PullNever PullStrategy = "never"
)

func ParsePullStrategy

func ParsePullStrategy(s string) (PullStrategy, error)

ParsePullStrategy converts a string to PullStrategy

Directories

Path Synopsis
Package handlers provides pluggable post-processing handlers for the Graft pipeline step.
Package handlers provides pluggable post-processing handlers for the Graft pipeline step.

Jump to

Keyboard shortcuts

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