pipeline

package
v0.3.0-dev.52 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2026 License: MIT Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package pipeline validates portable pipeline declarations and binds one authenticated entry to reviewed platform workers. It does not authenticate requests, fetch source, install workflows, or give out credentials.

Index

Constants

View Source
const MaxDocument = 128 * 1024

Variables

This section is empty.

Functions

func Audience

func Audience(k EntryKey) string

Audience binds a verified token to one entry. The audience is chosen by CI, so verify it together with that entry's workflow and ref policy.

func Validate

func Validate(m Manifest, c Catalog) error

Validate is the offline CI check. Visibility in the catalog is not a grant.

Types

type Bound

type Bound struct {
	// contains filtered or unexported fields
}

Bound is a validated graph for exactly one registration. Consumers must pin its source/definition digest in authoritative state before running it.

func (Bound) NewWorkflow

func (b Bound) NewWorkflow(stack *core.Stack, p workflow.PipelineProps, workers map[Ref]xyops.EventRef) (*workflow.Pipeline, error)

NewWorkflow resolves private worker references only at synthesis. Job params are correlation hints, NOT credentials. A worker must authorize its real workflow, node and ancestor using records outside caller-controlled input.

func (Bound) Source

func (b Bound) Source() Source

func (Bound) Steps

func (b Bound) Steps() []Step

func (Bound) WorkflowID

func (b Bound) WorkflowID() string

type Capability

type Capability struct {
	Ref     Ref    `json:"ref"`
	Input   Ref    `json:"input"`
	Output  Ref    `json:"output"`
	Summary string `json:"summary"`
}

type Catalog

type Catalog struct {
	Version      int          `json:"version"`
	Capabilities []Capability `json:"capabilities"`
}

func ParseCatalog

func ParseCatalog(data []byte) (Catalog, error)

ParseCatalog rejects unknown fields; this public document must not contain worker refs, grant data, deploy destinations, or secrets.

func (Catalog) JSON

func (c Catalog) JSON() ([]byte, error)

JSON is deterministic and satisfies core.Document. Contract types are versioned nominal records owned by the workers; they are not caller data.

type EntryKey

type EntryKey struct {
	RepositoryID uint64
	Entry        string
}

EntryKey is independent of workflow placement. The entry name must be bound to authenticated evidence (for example the OIDC audience) by the adapter.

type Manifest

type Manifest struct {
	Version   int    `json:"version"`
	Pipelines []Spec `json:"pipelines"`
}

A repository can carry independent application and infrastructure entries. Entry is a logical name, not an xyOps workflow ID or a permission.

func ParseManifest

func ParseManifest(data []byte) (Manifest, error)

type Ref

type Ref string

type RefPolicy

type RefPolicy string
const (
	Main RefPolicy = "main"
	Tag  RefPolicy = "release_tag"
)

type Registration

type Registration struct {
	EntryKey
	Pipeline, Environment, WorkflowID string
	Workflow                          string
	RefPolicy                         RefPolicy
	Input, Output                     Ref
	Grants                            []Ref
}

Registration is private site policy. Input and Output pin the entry boundary even if a contributor edits the manifest. A successful release cannot skip a mandatory capability by ending with a weaker output.

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

func NewRegistry

func NewRegistry(c Catalog, registrations ...Registration) (Registry, error)

func (Registry) Bind

func (r Registry) Bind(src Source, m Manifest) (Bound, error)

type Source

type Source struct {
	EntryKey
	Workflow, Ref, Commit, Audience string
}

Source is populated ONLY after verifying identity, release/branch, revision, and exact-commit CI against authoritative records. This type is not proof.

type Spec

type Spec struct {
	// Secrets requests logical names, never values, environment overrides or vault IDs.
	// Management adapters compare these with trusted grants before executing.
	Secrets []string `json:"secrets,omitempty"`
	Entry   string   `json:"entry"`
	Input   Ref      `json:"input"`
	Steps   []Step   `json:"steps"`
}

type Step

type Step struct {
	ID  string `json:"id"`
	Use Ref    `json:"use"`
}

Jump to

Keyboard shortcuts

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