platform

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CapabilityPolicy

type CapabilityPolicy struct {
	Filesystems bool
	ZFS         bool
	OSRelease   bool
}

CapabilityPolicy captures coarse target-level fact applicability.

type GateMetadata

type GateMetadata struct {
	GOOS        string
	Name        string
	CIJob       string
	LocalTarget string
	Script      string
	LabGuest    string
}

GateMetadata names the native gate associated with a target without storing lab-specific hosts, credentials, or other local environment details.

func NativeGates

func NativeGates() []GateMetadata

NativeGates returns target gate metadata in stable target order.

type IdentityPolicy

type IdentityPolicy struct {
	OSFamily   string
	OSName     string
	KernelName string
}

IdentityPolicy captures the default OS and kernel identity for a target.

type Profile

type Profile struct {
	ID                  string
	Label               string
	SupportTier         SupportTier
	SchemaVisible       bool
	CompileTargets      []Target
	DistributionTargets []Target
	Gate                GateMetadata
	Identity            IdentityPolicy
	Capabilities        CapabilityPolicy
}

Profile is the internal policy profile for one GOOS target.

func Lookup

func Lookup(goos string) (Profile, bool)

Lookup returns the target profile for goos.

func Profiles

func Profiles() []Profile

Profiles returns all target profiles in stable policy order.

func SchemaVisibleProfiles

func SchemaVisibleProfiles() []Profile

SchemaVisibleProfiles returns profiles accepted by the facts schema.

type SupportTier

type SupportTier string

SupportTier classifies the policy status for a platform target.

const (
	SupportTierRelease      SupportTier = "release"
	SupportTierLabValidated SupportTier = "lab_validated"
)

type Target

type Target struct {
	GOOS   string
	GOARCH string
}

Target is one GOOS/GOARCH build or distribution tuple.

func CompileTargets

func CompileTargets() []Target

CompileTargets returns the cross-compile target set in stable order.

func DistributionTargets

func DistributionTargets() []Target

DistributionTargets returns the published artifact target set in stable order.

Jump to

Keyboard shortcuts

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