Documentation
¶
Index ¶
- Constants
- func Register(f Func) error
- func RegisterVersion(f Func, v string) error
- func RegisteredFunctions() map[string]struct{}
- type Func
- type Phase
- func (p *Phase) Exec(ctx context.Context, bp crv1alpha1.Blueprint, action string, ...) (map[string]interface{}, error)
- func (p *Phase) Name() string
- func (p *Phase) Objects() map[string]crv1alpha1.ObjectReference
- func (p *Phase) Progress() (crv1alpha1.PhaseProgress, error)
- func (p *Phase) Validate(args map[string]any) error
Constants ¶
View Source
const (
DefaultVersion = "v0.0.0"
)
Variables ¶
This section is empty.
Functions ¶
func RegisterVersion ¶
RegisterVersion allows a Kanister Function to be registered with the given version
func RegisteredFunctions ¶
func RegisteredFunctions() map[string]struct{}
Types ¶
type Func ¶
type Func interface { Name() string RequiredArgs() []string Arguments() []string Exec(context.Context, param.TemplateParams, map[string]interface{}) (map[string]interface{}, error) ExecutionProgress() (crv1alpha1.PhaseProgress, error) Validate(map[string]any) error }
Func allows custom actions to be executed.
func KanisterFuncForName ¶
type Phase ¶
type Phase struct {
// contains filtered or unexported fields
}
Phase is an atomic unit of execution.
func GetDeferPhase ¶
func GetDeferPhase(bp crv1alpha1.Blueprint, action, version string, tp param.TemplateParams) (*Phase, error)
func GetPhases ¶
func GetPhases(bp crv1alpha1.Blueprint, action, version string, tp param.TemplateParams) ([]*Phase, error)
GetPhases renders the returns a list of Phases with pre-rendered arguments.
func (*Phase) Exec ¶
func (p *Phase) Exec(ctx context.Context, bp crv1alpha1.Blueprint, action string, tp param.TemplateParams) (map[string]interface{}, error)
Exec renders the argument templates in this Phase's Func and executes with those arguments.
func (*Phase) Objects ¶
func (p *Phase) Objects() map[string]crv1alpha1.ObjectReference
Objects returns the phase object references
func (*Phase) Progress ¶
func (p *Phase) Progress() (crv1alpha1.PhaseProgress, error)
Progress return execution progress of the phase.
Directories
¶
Path | Synopsis |
---|---|
apis
|
|
cr/v1alpha1
Package v1alpha1 is the v1alpha1 version of the API.
|
Package v1alpha1 is the v1alpha1 version of the API. |
azure
TODO: Switch to using the latest azure sdk and remove nolint.
|
TODO: Switch to using the latest azure sdk and remove nolint. |
client
|
|
clientset/versioned/fake
This package has the automatically generated fake clientset.
|
This package has the automatically generated fake clientset. |
clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
|
This package contains the scheme of the automatically generated clientset. |
clientset/versioned/typed/cr/v1alpha1
This package has the automatically generated typed clients.
|
This package has the automatically generated typed clients. |
clientset/versioned/typed/cr/v1alpha1/fake
Package fake has the automatically generated clients.
|
Package fake has the automatically generated clients. |
Package consts declares all the constants.
|
Package consts declares all the constants. |
controllers
|
|
Package kancontroller is for a kanister operator.
|
Package kancontroller is for a kanister operator. |
snapshot/mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
Package logsafe provides a framework for constructing commands that are safe for logging, where each token is considered unsafe and redacted, unless explicitly specified.
|
Package logsafe provides a framework for constructing commands that are safe for logging, where each token is considered unsafe and redacted, unless explicitly specified. |
repositoryserver
Package repositoryserver validates the secret credentials for all location profiles.
|
Package repositoryserver validates the secret credentials for all location profiles. |
testing
|
|
Click to show internal directories.
Click to hide internal directories.