Documentation ¶
Index ¶
- Variables
- type ApplyNetorkPoliciesConfig
- type ApplyNetorkPoliciesOption
- type CSVClient
- type CSVClientImpl
- type CSVClientImplConfig
- type CSVClientOption
- type ConfigMapUninstallSignaler
- type ConfigMapUninstallSignalerConfig
- type ConfigMapUninstallSignalerOption
- type ListCSVsConfig
- type ListCSVsOption
- type NetworkPolicyClient
- type NetworkPolicyClientImpl
- type ParameterGetter
- type Phase
- type PhaseApplyNetworkPolicies
- type PhaseApplyNetworkPoliciesConfig
- type PhaseApplyNetworkPoliciesOption
- type PhaseRequest
- type PhaseRequestParameters
- type PhaseRequestParametersConfig
- type PhaseRequestParametersOption
- type PhaseResult
- type PhaseResultConfig
- type PhaseResultOption
- type PhaseSendDummyMetrics
- type PhaseSendDummyMetricsConfig
- type PhaseSendDummyMetricsOption
- type PhaseSmokeTestRun
- type PhaseSmokeTestRunConfig
- type PhaseSmokeTestRunOption
- type PhaseStatus
- type PhaseUninstall
- type PhaseUninstallConfig
- type PhaseUninstallOption
- type ReferenceAddonClient
- type ReferenceAddonClientImpl
- type ReferenceAddonReconciler
- type ReferenceAddonReconcilerConfig
- type ReferenceAddonReconcilerOption
- type ResponseSampler
- type SecretParameterGetter
- type SecretParameterGetterConfig
- type SecretParameteterGetterOption
- type SmokeTester
- type UninstallSignaler
- type Uninstaller
- type UninstallerImpl
- type UninstallerImplConfig
- type UninstallerImplOption
- type WithAddonNamespace
- type WithAddonParameterSecretName
- type WithApplyNetworkPolicies
- type WithConditions
- type WithDeleteLabel
- type WithEnableSmokeTest
- type WithLog
- func (w WithLog) ConfigureCSVClientImpl(c *CSVClientImplConfig)
- func (w WithLog) ConfigurePhaseApplyNetworkPolicies(c *PhaseApplyNetworkPoliciesConfig)
- func (w WithLog) ConfigurePhaseSmokeTestRun(c *PhaseSmokeTestRunConfig)
- func (w WithLog) ConfigurePhaseUninstall(c *PhaseUninstallConfig)
- func (w WithLog) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
- func (w WithLog) ConfigureUninstallerImpl(c *UninstallerImplConfig)
- type WithName
- type WithNamespace
- type WithOperatorName
- type WithOwner
- type WithPolicies
- type WithPrefix
- type WithSampleURLs
- type WithSize
- type WithSmokeTester
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidBoolValue = errors.New("invalid bool value")
Functions ¶
This section is empty.
Types ¶
type ApplyNetorkPoliciesConfig ¶
type ApplyNetorkPoliciesConfig struct { Owner metav1.Object Policies []netv1.NetworkPolicy }
func (*ApplyNetorkPoliciesConfig) Option ¶
func (c *ApplyNetorkPoliciesConfig) Option(opts ...ApplyNetorkPoliciesOption)
type ApplyNetorkPoliciesOption ¶
type ApplyNetorkPoliciesOption interface {
ConfigureApplyNetworkPolicies(c *ApplyNetorkPoliciesConfig)
}
type CSVClient ¶
type CSVClient interface { ListCSVs(ctx context.Context, opts ...ListCSVsOption) ([]opsv1alpha1.ClusterServiceVersion, error) RemoveCSVs(ctx context.Context, csvs ...opsv1alpha1.ClusterServiceVersion) error }
type CSVClientImpl ¶
type CSVClientImpl struct {
// contains filtered or unexported fields
}
func NewCSVClientImpl ¶
func NewCSVClientImpl(client client.Client, opts ...CSVClientOption) *CSVClientImpl
func (*CSVClientImpl) ListCSVs ¶
func (c *CSVClientImpl) ListCSVs(ctx context.Context, opts ...ListCSVsOption) ([]opsv1alpha1.ClusterServiceVersion, error)
func (*CSVClientImpl) RemoveCSVs ¶
func (c *CSVClientImpl) RemoveCSVs(ctx context.Context, csvs ...opsv1alpha1.ClusterServiceVersion) error
type CSVClientImplConfig ¶
func (*CSVClientImplConfig) Default ¶
func (c *CSVClientImplConfig) Default()
func (*CSVClientImplConfig) Option ¶
func (c *CSVClientImplConfig) Option(opts ...CSVClientOption)
type CSVClientOption ¶
type CSVClientOption interface {
ConfigureCSVClientImpl(*CSVClientImplConfig)
}
type ConfigMapUninstallSignaler ¶
type ConfigMapUninstallSignaler struct {
// contains filtered or unexported fields
}
func NewConfigMapUninstallSignaler ¶
func NewConfigMapUninstallSignaler(client client.Client, opts ...ConfigMapUninstallSignalerOption) (*ConfigMapUninstallSignaler, error)
func (*ConfigMapUninstallSignaler) SignalUninstall ¶
func (s *ConfigMapUninstallSignaler) SignalUninstall(ctx context.Context) bool
type ConfigMapUninstallSignalerConfig ¶
type ConfigMapUninstallSignalerConfig struct { AddonNamespace string OperatorName string DeleteLabel string }
func (*ConfigMapUninstallSignalerConfig) Option ¶
func (c *ConfigMapUninstallSignalerConfig) Option(opts ...ConfigMapUninstallSignalerOption)
func (*ConfigMapUninstallSignalerConfig) Validate ¶
func (c *ConfigMapUninstallSignalerConfig) Validate() error
type ConfigMapUninstallSignalerOption ¶
type ConfigMapUninstallSignalerOption interface {
ConfigureConfigMapUninstallSignaler(*ConfigMapUninstallSignalerConfig)
}
type ListCSVsConfig ¶
func (*ListCSVsConfig) Option ¶
func (c *ListCSVsConfig) Option(opts ...ListCSVsOption)
type ListCSVsOption ¶
type ListCSVsOption interface {
ConfigureListCSVs(*ListCSVsConfig)
}
type NetworkPolicyClient ¶
type NetworkPolicyClient interface { ApplyNetworkPolicies(ctx context.Context, opts ...ApplyNetorkPoliciesOption) error RemoveNetworkPolicies(ctx context.Context, policies ...netv1.NetworkPolicy) error }
type NetworkPolicyClientImpl ¶
type NetworkPolicyClientImpl struct {
// contains filtered or unexported fields
}
func NewNetworkPolicyClientImpl ¶
func NewNetworkPolicyClientImpl(client client.Client) *NetworkPolicyClientImpl
func (*NetworkPolicyClientImpl) ApplyNetworkPolicies ¶
func (c *NetworkPolicyClientImpl) ApplyNetworkPolicies(ctx context.Context, opts ...ApplyNetorkPoliciesOption) error
func (*NetworkPolicyClientImpl) RemoveNetworkPolicies ¶
func (c *NetworkPolicyClientImpl) RemoveNetworkPolicies(ctx context.Context, policies ...netv1.NetworkPolicy) error
type ParameterGetter ¶
type ParameterGetter interface {
GetParameters(ctx context.Context) (PhaseRequestParameters, error)
}
type Phase ¶
type Phase interface {
Execute(ctx context.Context, req PhaseRequest) PhaseResult
}
type PhaseApplyNetworkPolicies ¶
type PhaseApplyNetworkPolicies struct {
// contains filtered or unexported fields
}
func NewPhaseApplyNetworkPolicies ¶
func NewPhaseApplyNetworkPolicies(client NetworkPolicyClient, opts ...PhaseApplyNetworkPoliciesOption) *PhaseApplyNetworkPolicies
func (*PhaseApplyNetworkPolicies) Execute ¶
func (p *PhaseApplyNetworkPolicies) Execute(ctx context.Context, req PhaseRequest) PhaseResult
type PhaseApplyNetworkPoliciesConfig ¶
type PhaseApplyNetworkPoliciesConfig struct { Log logr.Logger Policies []netv1.NetworkPolicy }
func (*PhaseApplyNetworkPoliciesConfig) Default ¶
func (c *PhaseApplyNetworkPoliciesConfig) Default()
func (*PhaseApplyNetworkPoliciesConfig) Option ¶
func (c *PhaseApplyNetworkPoliciesConfig) Option(opts ...PhaseApplyNetworkPoliciesOption)
type PhaseApplyNetworkPoliciesOption ¶
type PhaseApplyNetworkPoliciesOption interface {
ConfigurePhaseApplyNetworkPolicies(*PhaseApplyNetworkPoliciesConfig)
}
type PhaseRequest ¶
type PhaseRequest struct { Addon refv1alpha1.ReferenceAddon Params PhaseRequestParameters }
type PhaseRequestParameters ¶
type PhaseRequestParameters struct {
// contains filtered or unexported fields
}
func NewPhaseRequestParameters ¶
func NewPhaseRequestParameters(opts ...PhaseRequestParametersOption) PhaseRequestParameters
func (*PhaseRequestParameters) GetApplyNetworkPolicies ¶
func (p *PhaseRequestParameters) GetApplyNetworkPolicies() (bool, bool)
func (*PhaseRequestParameters) GetEnableSmokeTest ¶ added in v0.9.0
func (p *PhaseRequestParameters) GetEnableSmokeTest() (bool, bool)
func (*PhaseRequestParameters) GetSize ¶
func (p *PhaseRequestParameters) GetSize() (string, bool)
type PhaseRequestParametersConfig ¶
type PhaseRequestParametersConfig struct { ApplyNetworkPolicies *bool EnableSmokeTest *bool Size *string }
func (*PhaseRequestParametersConfig) Option ¶
func (c *PhaseRequestParametersConfig) Option(opts ...PhaseRequestParametersOption)
type PhaseRequestParametersOption ¶
type PhaseRequestParametersOption interface {
ConfigurePhaseRequestParameters(*PhaseRequestParametersConfig)
}
type PhaseResult ¶
type PhaseResult struct {
// contains filtered or unexported fields
}
func PhaseResultBlocking ¶
func PhaseResultBlocking(opts ...PhaseResultOption) PhaseResult
func PhaseResultError ¶
func PhaseResultError(err error, opts ...PhaseResultOption) PhaseResult
func PhaseResultFailure ¶
func PhaseResultFailure(msg string, opts ...PhaseResultOption) PhaseResult
func PhaseResultSuccess ¶
func PhaseResultSuccess(opts ...PhaseResultOption) PhaseResult
func (PhaseResult) Conditions ¶
func (r PhaseResult) Conditions() []metav1.Condition
func (PhaseResult) Error ¶
func (r PhaseResult) Error() error
func (PhaseResult) FailureMessage ¶
func (r PhaseResult) FailureMessage() string
func (PhaseResult) Status ¶
func (r PhaseResult) Status() PhaseStatus
type PhaseResultConfig ¶
func (*PhaseResultConfig) Option ¶
func (c *PhaseResultConfig) Option(opts ...PhaseResultOption)
type PhaseResultOption ¶
type PhaseResultOption interface {
ConfigurePhaseResult(c *PhaseResultConfig)
}
type PhaseSendDummyMetrics ¶
type PhaseSendDummyMetrics struct {
// contains filtered or unexported fields
}
func NewPhaseSendDummyMetrics ¶
func NewPhaseSendDummyMetrics(sampler ResponseSampler, opts ...PhaseSendDummyMetricsOption) *PhaseSendDummyMetrics
func (*PhaseSendDummyMetrics) Execute ¶
func (p *PhaseSendDummyMetrics) Execute(ctx context.Context, req PhaseRequest) PhaseResult
type PhaseSendDummyMetricsConfig ¶
type PhaseSendDummyMetricsConfig struct {
SampleURLs []string
}
func (*PhaseSendDummyMetricsConfig) Option ¶
func (c *PhaseSendDummyMetricsConfig) Option(opts ...PhaseSendDummyMetricsOption)
type PhaseSendDummyMetricsOption ¶
type PhaseSendDummyMetricsOption interface {
ConfigurePhaseSendDummyMetrics(*PhaseSendDummyMetricsConfig)
}
type PhaseSmokeTestRun ¶ added in v0.9.0
type PhaseSmokeTestRun struct {
// contains filtered or unexported fields
}
func NewPhaseSmokeTestRun ¶ added in v0.9.0
func NewPhaseSmokeTestRun(opts ...PhaseSmokeTestRunOption) *PhaseSmokeTestRun
func (*PhaseSmokeTestRun) Execute ¶ added in v0.9.0
func (p *PhaseSmokeTestRun) Execute(_ context.Context, req PhaseRequest) PhaseResult
type PhaseSmokeTestRunConfig ¶ added in v0.9.0
type PhaseSmokeTestRunConfig struct { Log logr.Logger SmokeTester SmokeTester }
func (*PhaseSmokeTestRunConfig) Default ¶ added in v0.9.0
func (c *PhaseSmokeTestRunConfig) Default()
func (*PhaseSmokeTestRunConfig) Option ¶ added in v0.9.0
func (c *PhaseSmokeTestRunConfig) Option(opts ...PhaseSmokeTestRunOption)
type PhaseSmokeTestRunOption ¶ added in v0.9.0
type PhaseSmokeTestRunOption interface {
ConfigurePhaseSmokeTestRun(*PhaseSmokeTestRunConfig)
}
type PhaseStatus ¶
type PhaseStatus string
const ( PhaseStatusBlocking PhaseStatus = "blocking" PhaseStatusError PhaseStatus = "error" PhaseStatusFailure PhaseStatus = "failure" PhaseStatusSuccess PhaseStatus = "success" )
func (PhaseStatus) String ¶
func (s PhaseStatus) String() string
type PhaseUninstall ¶
type PhaseUninstall struct {
// contains filtered or unexported fields
}
func NewPhaseUninstall ¶
func NewPhaseUninstall(signaler UninstallSignaler, uninstaller Uninstaller, opts ...PhaseUninstallOption) *PhaseUninstall
func (*PhaseUninstall) Execute ¶
func (p *PhaseUninstall) Execute(ctx context.Context, req PhaseRequest) PhaseResult
type PhaseUninstallConfig ¶
func (*PhaseUninstallConfig) Default ¶
func (c *PhaseUninstallConfig) Default()
func (*PhaseUninstallConfig) Option ¶
func (c *PhaseUninstallConfig) Option(opts ...PhaseUninstallOption)
type PhaseUninstallOption ¶
type PhaseUninstallOption interface {
ConfigurePhaseUninstall(*PhaseUninstallConfig)
}
type ReferenceAddonClient ¶
type ReferenceAddonClient interface { CreateOrUpdate(ctx context.Context, addon refv1alpha1.ReferenceAddon) (*refv1alpha1.ReferenceAddon, error) UpdateStatus(ctx context.Context, addon *refv1alpha1.ReferenceAddon) error }
type ReferenceAddonClientImpl ¶
type ReferenceAddonClientImpl struct {
// contains filtered or unexported fields
}
func NewReferenceAddonClient ¶
func NewReferenceAddonClient(client client.Client) *ReferenceAddonClientImpl
func (*ReferenceAddonClientImpl) CreateOrUpdate ¶
func (c *ReferenceAddonClientImpl) CreateOrUpdate(ctx context.Context, addon refv1alpha1.ReferenceAddon) (*refv1alpha1.ReferenceAddon, error)
func (*ReferenceAddonClientImpl) UpdateStatus ¶
func (c *ReferenceAddonClientImpl) UpdateStatus(ctx context.Context, addon *refv1alpha1.ReferenceAddon) error
type ReferenceAddonReconciler ¶
type ReferenceAddonReconciler struct {
// contains filtered or unexported fields
}
func NewReferenceAddonReconciler ¶
func NewReferenceAddonReconciler(client client.Client, getter ParameterGetter, opts ...ReferenceAddonReconcilerOption) (*ReferenceAddonReconciler, error)
func (*ReferenceAddonReconciler) SetupWithManager ¶
func (r *ReferenceAddonReconciler) SetupWithManager(mgr ctrl.Manager) error
type ReferenceAddonReconcilerConfig ¶
type ReferenceAddonReconcilerConfig struct { Log logr.Logger AddonNamespace string AddonParameterSecretname string OperatorName string DeleteLabel string }
func (*ReferenceAddonReconcilerConfig) Default ¶
func (c *ReferenceAddonReconcilerConfig) Default()
func (*ReferenceAddonReconcilerConfig) Option ¶
func (c *ReferenceAddonReconcilerConfig) Option(opts ...ReferenceAddonReconcilerOption)
type ReferenceAddonReconcilerOption ¶
type ReferenceAddonReconcilerOption interface {
ConfigureReferenceAddonReconciler(*ReferenceAddonReconcilerConfig)
}
type ResponseSampler ¶
type ResponseSampler interface {
RequestSampleResponseData(urls ...string)
}
type SecretParameterGetter ¶
type SecretParameterGetter struct {
// contains filtered or unexported fields
}
func NewSecretParameterGetter ¶
func NewSecretParameterGetter(client client.Client, opts ...SecretParameteterGetterOption) *SecretParameterGetter
func (*SecretParameterGetter) GetParameters ¶
func (s *SecretParameterGetter) GetParameters(ctx context.Context) (PhaseRequestParameters, error)
type SecretParameterGetterConfig ¶
func (*SecretParameterGetterConfig) Option ¶
func (c *SecretParameterGetterConfig) Option(opts ...SecretParameteterGetterOption)
type SecretParameteterGetterOption ¶
type SecretParameteterGetterOption interface {
ConfigureSecretParameterGetter(*SecretParameterGetterConfig)
}
type SmokeTester ¶ added in v0.9.0
type SmokeTester interface { Enable() Disable() }
type UninstallSignaler ¶
type Uninstaller ¶
type UninstallerImpl ¶
type UninstallerImpl struct {
// contains filtered or unexported fields
}
func NewUninstallerImpl ¶
func NewUninstallerImpl(client CSVClient, opts ...UninstallerImplOption) *UninstallerImpl
type UninstallerImplConfig ¶
func (*UninstallerImplConfig) Default ¶
func (c *UninstallerImplConfig) Default()
func (*UninstallerImplConfig) Option ¶
func (c *UninstallerImplConfig) Option(opts ...UninstallerImplOption)
type UninstallerImplOption ¶
type UninstallerImplOption interface {
ConfigureUninstallerImpl(*UninstallerImplConfig)
}
type WithAddonNamespace ¶
type WithAddonNamespace string
func (WithAddonNamespace) ConfigureConfigMapUninstallSignaler ¶
func (w WithAddonNamespace) ConfigureConfigMapUninstallSignaler(c *ConfigMapUninstallSignalerConfig)
func (WithAddonNamespace) ConfigurePhaseUninstall ¶
func (w WithAddonNamespace) ConfigurePhaseUninstall(c *PhaseUninstallConfig)
func (WithAddonNamespace) ConfigureReferenceAddonReconciler ¶
func (w WithAddonNamespace) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
type WithAddonParameterSecretName ¶
type WithAddonParameterSecretName string
func (WithAddonParameterSecretName) ConfigureReferenceAddonReconciler ¶
func (w WithAddonParameterSecretName) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
type WithApplyNetworkPolicies ¶
type WithApplyNetworkPolicies struct{ Value *bool }
func (WithApplyNetworkPolicies) ConfigurePhaseRequestParameters ¶
func (w WithApplyNetworkPolicies) ConfigurePhaseRequestParameters(c *PhaseRequestParametersConfig)
type WithConditions ¶
func (WithConditions) ConfigurePhaseResult ¶
func (w WithConditions) ConfigurePhaseResult(c *PhaseResultConfig)
type WithDeleteLabel ¶
type WithDeleteLabel string
func (WithDeleteLabel) ConfigureConfigMapUninstallSignaler ¶
func (w WithDeleteLabel) ConfigureConfigMapUninstallSignaler(c *ConfigMapUninstallSignalerConfig)
func (WithDeleteLabel) ConfigureReferenceAddonReconciler ¶
func (w WithDeleteLabel) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
type WithEnableSmokeTest ¶ added in v0.9.0
type WithEnableSmokeTest struct{ Value *bool }
func (WithEnableSmokeTest) ConfigurePhaseRequestParameters ¶ added in v0.9.0
func (w WithEnableSmokeTest) ConfigurePhaseRequestParameters(c *PhaseRequestParametersConfig)
type WithLog ¶
func (WithLog) ConfigureCSVClientImpl ¶
func (w WithLog) ConfigureCSVClientImpl(c *CSVClientImplConfig)
func (WithLog) ConfigurePhaseApplyNetworkPolicies ¶
func (w WithLog) ConfigurePhaseApplyNetworkPolicies(c *PhaseApplyNetworkPoliciesConfig)
func (WithLog) ConfigurePhaseSmokeTestRun ¶ added in v0.9.0
func (w WithLog) ConfigurePhaseSmokeTestRun(c *PhaseSmokeTestRunConfig)
func (WithLog) ConfigurePhaseUninstall ¶
func (w WithLog) ConfigurePhaseUninstall(c *PhaseUninstallConfig)
func (WithLog) ConfigureReferenceAddonReconciler ¶
func (w WithLog) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
func (WithLog) ConfigureUninstallerImpl ¶
func (w WithLog) ConfigureUninstallerImpl(c *UninstallerImplConfig)
type WithName ¶
type WithName string
func (WithName) ConfigureSecretParameterGetter ¶
func (w WithName) ConfigureSecretParameterGetter(c *SecretParameterGetterConfig)
type WithNamespace ¶
type WithNamespace string
func (WithNamespace) ConfigureListCSVs ¶
func (w WithNamespace) ConfigureListCSVs(c *ListCSVsConfig)
func (WithNamespace) ConfigureSecretParameterGetter ¶
func (w WithNamespace) ConfigureSecretParameterGetter(c *SecretParameterGetterConfig)
type WithOperatorName ¶
type WithOperatorName string
func (WithOperatorName) ConfigureConfigMapUninstallSignaler ¶
func (w WithOperatorName) ConfigureConfigMapUninstallSignaler(c *ConfigMapUninstallSignalerConfig)
func (WithOperatorName) ConfigurePhaseUninstall ¶
func (w WithOperatorName) ConfigurePhaseUninstall(c *PhaseUninstallConfig)
func (WithOperatorName) ConfigureReferenceAddonReconciler ¶
func (w WithOperatorName) ConfigureReferenceAddonReconciler(c *ReferenceAddonReconcilerConfig)
type WithOwner ¶
func (WithOwner) ConfigureApplyNetworkPolicies ¶
func (w WithOwner) ConfigureApplyNetworkPolicies(c *ApplyNetorkPoliciesConfig)
type WithPolicies ¶
type WithPolicies []netv1.NetworkPolicy
func (WithPolicies) ConfigureApplyNetworkPolicies ¶
func (w WithPolicies) ConfigureApplyNetworkPolicies(c *ApplyNetorkPoliciesConfig)
func (WithPolicies) ConfigurePhaseApplyNetworkPolicies ¶
func (w WithPolicies) ConfigurePhaseApplyNetworkPolicies(c *PhaseApplyNetworkPoliciesConfig)
type WithPrefix ¶
type WithPrefix string
func (WithPrefix) ConfigureListCSVs ¶
func (w WithPrefix) ConfigureListCSVs(c *ListCSVsConfig)
type WithSampleURLs ¶
type WithSampleURLs []string
func (WithSampleURLs) ConfigurePhaseSendDummyMetrics ¶
func (w WithSampleURLs) ConfigurePhaseSendDummyMetrics(c *PhaseSendDummyMetricsConfig)
type WithSize ¶
type WithSize struct{ Value *string }
func (WithSize) ConfigurePhaseRequestParameters ¶
func (w WithSize) ConfigurePhaseRequestParameters(c *PhaseRequestParametersConfig)
type WithSmokeTester ¶ added in v0.9.0
type WithSmokeTester struct{ Tester SmokeTester }
func (WithSmokeTester) ConfigurePhaseSmokeTestRun ¶ added in v0.9.0
func (w WithSmokeTester) ConfigurePhaseSmokeTestRun(c *PhaseSmokeTestRunConfig)
Click to show internal directories.
Click to hide internal directories.