Documentation
¶
Index ¶
- Constants
- Variables
- type EndpointSchema
- type HelmRepositoryData
- func GetHelmRepositoryData(ctx context.Context, configMapClient configMapInterface) (*HelmRepositoryData, error)
- func NewHelmRepoDataFromCluster(ctx context.Context, configMapClient configMapInterface) (*HelmRepositoryData, error)
- func NewHelmRepoDataFromFile(filepath string) (*HelmRepositoryData, error)
- type OperatorConfig
Constants ¶
View Source
const ( // StageDevelopment is the name for the development-stage StageDevelopment = "development" // StageProduction is the name for the production-stage StageProduction = "production" // StageEnvironmentVariable is the name of the environment-variable containing the configured stage StageEnvironmentVariable = "STAGE" // RequeueTimeInNanosecondsEnvironmentVariable is the name of the environment variable containing the configured requeueTime RequeueTimeInNanosecondsEnvironmentVariable = "REQUEUE_TIME_IN_NANOSECONDS" )
Variables ¶
View Source
var (
Stage = StageProduction
)
Functions ¶
This section is empty.
Types ¶
type EndpointSchema ¶ added in v0.1.0
type EndpointSchema string
const EndpointSchemaOCI EndpointSchema = "oci"
type HelmRepositoryData ¶
type HelmRepositoryData struct {
// Endpoint contains the Helm registry endpoint URL.
Endpoint string `json:"endpoint" yaml:"endpoint"`
// Schema describes the way how clients communicate with the Helm registry endpoint.
Schema EndpointSchema `json:"schema" yaml:"schema"`
// PlainHttp indicates that the repository endpoint should be accessed using plain http
PlainHttp bool `json:"plainHttp,omitempty" yaml:"plainHttp,omitempty"`
// InsecureTls allows invalid or selfsigned certificates to be used. This option may be overridden by PlainHttp which forces HTTP traffic.
InsecureTLS bool `json:"insecureTls" yaml:"insecureTls"`
}
HelmRepositoryData contains all necessary data for the helm repository.
func GetHelmRepositoryData ¶
func GetHelmRepositoryData(ctx context.Context, configMapClient configMapInterface) (*HelmRepositoryData, error)
GetHelmRepositoryData reads the repository data either from file or from a secret in the cluster.
func NewHelmRepoDataFromCluster ¶ added in v0.1.0
func NewHelmRepoDataFromCluster(ctx context.Context, configMapClient configMapInterface) (*HelmRepositoryData, error)
NewHelmRepoDataFromCluster reads the repo data ConfigMap, validates and returns it.
func NewHelmRepoDataFromFile ¶ added in v0.1.0
func NewHelmRepoDataFromFile(filepath string) (*HelmRepositoryData, error)
func (*HelmRepositoryData) URL ¶ added in v0.1.1
func (hrd *HelmRepositoryData) URL() string
URL returns the full URL Helm repository endpoint including schema.
type OperatorConfig ¶
type OperatorConfig struct {
// Namespace specifies the namespace that the operator is deployed to.
Namespace string `json:"namespace"`
// Version contains the current version of the operator
Version *semver.Version `json:"version"`
// HelmRepositoryData contains all necessary data for the helm repository.
HelmRepositoryData *HelmRepositoryData `json:"helm_repository"`
HelmClientTimeoutMins time.Duration
HealthSyncIntervalMins time.Duration
RequeueTime time.Duration
}
OperatorConfig contains all configurable values for the component operator.
func NewOperatorConfig ¶
func NewOperatorConfig(version string) (*OperatorConfig, error)
NewOperatorConfig creates a new operator config by reading values from the environment variables
Click to show internal directories.
Click to hide internal directories.