Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Adapter ¶
type Adapter interface { Fetch(cfg AdapterConfig) (string, error) Validate(cfg AdapterConfig) error }
An Adapter is used to load a version string from a specific target / technology / transport
type AdapterConfig ¶
type AdapterConfig struct { Type AdapterType `yaml:"type"` GitHubRelease GitHubRelease `yaml:"gitHubRelease"` HttpGet HttpGet `yaml:"httpGet"` K8sContainerImage K8sContainerImage `yaml:"k8sContainerImage,omitempty"` ShellCommand ShellCommand `yaml:"shellCommand"` }
AdapterConfig config section
type AdapterRegistry ¶
type AdapterRegistry map[AdapterType]Adapter
AdapterRegistry is a registry for adapters ... wow
type AdapterType ¶
type AdapterType string
AdapterType defines the adapter to use to load the version from
type Config ¶
type Config struct {
Targets []Target `yaml:"targets"`
}
Config root object, just a list of targets
type GitHubRelease ¶
GitHubRelease config section
func (GitHubRelease) String ¶
func (g GitHubRelease) String() string
String implements the fmt.Stringer interface
type K8sContainerImage ¶
type K8sContainerImage struct { Kind string `yaml:"kind"` Namespace string `yaml:"namespace"` Name string `yaml:"name"` ContainerName string `yaml:"containerName,omitempty"` }
K8sContainerImage config section
func (K8sContainerImage) String ¶
func (k K8sContainerImage) String() string
String implements the fmt.Stringer interface
type ShellCommand ¶
ShellCommand config section
func (ShellCommand) String ¶
func (s ShellCommand) String() string
String implements the fmt.Stringer interface
type Target ¶
type Target struct { Name string `yaml:"name"` Current AdapterConfig `yaml:"current"` Latest AdapterConfig `yaml:"latest"` }
Target specifies a single target
Click to show internal directories.
Click to hide internal directories.