compose

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2026 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

Package compose produces team-owned kukeon documents without contacting a daemon, fetching sources, reading credentials, or writing files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SelectImage

func SelectImage(c *harness.ImageCatalog, name string, needs []string) (harness.CatalogImage, error)

SelectImage preserves catalog order and requires one published image to carry the selected harness plus all mandatory and additive capabilities.

Types

type Options

type Options struct {
	Sources map[string]fs.FS
	Scope   Scope
	// HomeDir is needed only for an explicitly requested ssh mount; it is not
	// discovered from the host.
	HomeDir string
	// Secrets are the bindings recorded in the team's existing TeamEntry; they
	// take precedence over global spec.secrets and generated defaults.
	Secrets []config.SecretBinding
}

Options supplies materialized definition sources. Each key is a selected source name; callers own fetching/pinning. Composition only reads these FSes.

type Pair

type Pair struct {
	Role      string
	Harness   string
	Image     harness.CatalogImage
	Blueprint *api.CellBlueprintDoc
	Config    *api.CellConfigDoc
	Secrets   []SecretRequirement
}

type Result

type Result struct {
	Entry *config.TeamEntry
	Pairs []Pair
}

Result keeps the authored declaration separate from resolved resources. Entry is a candidate for #13 to persist only after successful application.

func Compose

func Compose(cfg *config.TeamsConfig, team *config.Team, opts Options) (*Result, error)

Compose resolves whole-list inheritance and selected role/harness pairs. The returned objects are independent of inputs and ordered by authored selections.

func (*Result) MarshalYAML

func (r *Result) MarshalYAML() ([]byte, error)

MarshalYAML returns only Blueprints then Configs. Secret values and creation source declarations are never part of the daemon document stream.

type Scope

type Scope struct{ Realm, Space, Stack string }

type SecretRequirement

type SecretRequirement struct {
	Identifier  string
	Container   string
	Destination api.BlueprintSecretSlot
	Reference   config.SecretRef
	Source      *config.SecretSource
}

SecretRequirement contains declarations only; Source is an optional creation fallback to read at application time, after runtime existence is checked.

Directories

Path Synopsis
Package renderers bundles the supported renderer with the executable, independently of the source supplying a Harness.
Package renderers bundles the supported renderer with the executable, independently of the source supplying a Harness.

Jump to

Keyboard shortcuts

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