Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Error ¶
type Error struct {
Nested error
Reason string
Message string
Name string
NonBlockingWarning bool // For some errors we do not want to fail the precondition check but we want to communicate about it
}
Error is a wrapper for errors that occur during a precondition check for payload.
type Precondition ¶
type Precondition interface {
// Run executes the precondition checks ands returns an error when the precondition fails.
Run(ctx context.Context, releaseContext ReleaseContext) error
// Name returns a human friendly name of the precondition.
Name() string
}
Precondition defines the precondition check for a payload.
type ReleaseContext ¶
type ReleaseContext struct {
// DesiredVersion is the version of the payload being considered.
// While this might be a semantic version, consumers should not
// require SemVer validity so they can handle custom releases
// where the author decided to use a different naming scheme, or
// to leave the version completely unset.
DesiredVersion string
}
ReleaseContext holds information about the update being considered
Click to show internal directories.
Click to hide internal directories.