Documentation
¶
Index ¶
- Variables
- func LoadSchema(pathOrURI string) (*schemaapi.CraftingSchema, error)
- func NewRunner(t schemaapi.CraftingSchema_Runner_RunnerType) supportedRunner
- type Crafter
- func (c *Crafter) AddMaterial(key, value string, casBackend *casclient.CASBackend, ...) error
- func (c *Crafter) AlreadyInitialized() bool
- func (c *Crafter) Init(opts *InitOpts) error
- func (c *Crafter) LoadCraftingState() error
- func (c *Crafter) Reset() error
- func (c *Crafter) ResolveEnvVars(strict bool) error
- func (c *Crafter) ValidateAttestation() error
- type InitOpts
- type NewOpt
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrAttestationStateNotLoaded = errors.New("crafting state not loaded")
View Source
var ErrRunnerContextNotFound = errors.New("the runner environment doesn't match the required runner type")
Functions ¶
func LoadSchema ¶
func LoadSchema(pathOrURI string) (*schemaapi.CraftingSchema, error)
func NewRunner ¶
func NewRunner(t schemaapi.CraftingSchema_Runner_RunnerType) supportedRunner
Types ¶
type Crafter ¶
type Crafter struct {
CraftingState *api.CraftingState
Runner supportedRunner
// contains filtered or unexported fields
}
func (*Crafter) AddMaterial ¶
func (c *Crafter) AddMaterial(key, value string, casBackend *casclient.CASBackend, runtimeAnnotations map[string]string) error
Inject material to attestation state
func (*Crafter) AlreadyInitialized ¶
func (*Crafter) LoadCraftingState ¶
func (*Crafter) ResolveEnvVars ¶
ResolveEnvVars will iterate on the env vars in the allow list and resolve them from the system context strict indicates if it should fail if any env variable can not be found
func (*Crafter) ValidateAttestation ¶
type InitOpts ¶
type InitOpts struct {
// Control plane workflow metadata
WfInfo *api.WorkflowMetadata
// already marshaled schema
SchemaV1 *schemaapi.CraftingSchema
// do not record, upload or push attestation
DryRun bool
}
Click to show internal directories.
Click to hide internal directories.