Documentation ¶
Index ¶
- Constants
- func ServiceObject(namespace string, appKubernetesPartOfValue string) *v1.Service
- func StartControllers(ctx context.Context, mgr controllerruntime.Manager, controllers []Controller) error
- type Controller
- func CreateControllers(ctx context.Context, apiReader client.Reader) ([]Controller, error)
- func CreateServiceController() (Controller, error)
- func NewSspController(infrastructureTopology osconfv1.TopologyMode, operands []operands.Operand) Controller
- func NewVmController() Controller
- func NewWebhookConfigurationController() Controller
- type ControllerReconciler
Constants ¶
View Source
const ( ServiceManagedByLabelValue = "ssp-operator-services" MetricsServiceName = "ssp-operator-metrics" OperatorName = "ssp-operator" ServiceControllerName = "service-controller" )
View Source
const ( OlmNameLabel = "olm.webhook-description-generate-name" OlmNameLabelValue = "validation.ssp.kubevirt.io" )
Variables ¶
This section is empty.
Functions ¶
func ServiceObject ¶
func StartControllers ¶
func StartControllers(ctx context.Context, mgr controllerruntime.Manager, controllers []Controller) error
Types ¶
type Controller ¶
type Controller interface { Name() string AddToManager(mgr ctrl.Manager, crdList crd_watch.CrdList) error RequiredCrds() []string }
func CreateControllers ¶
func CreateServiceController ¶
func CreateServiceController() (Controller, error)
func NewSspController ¶
func NewSspController(infrastructureTopology osconfv1.TopologyMode, operands []operands.Operand) Controller
func NewVmController ¶
func NewVmController() Controller
func NewWebhookConfigurationController ¶
func NewWebhookConfigurationController() Controller
CreateWebhookConfigurationController creates a controller that watches ValidatingWebhookConfiguration created by OLM, and removes any namespaceSelector defined in it.
The OLM limits the webhook scope to the namespaces that are defined in the OperatorGroup by setting namespaceSelector in the ValidatingWebhookConfiguration. We would like our webhook to intercept requests from all namespaces.
The SSP operator already watches all ValidatingWebhookConfigurations, because of template validator operand, so this controller is not a performance issue.
type ControllerReconciler ¶
Click to show internal directories.
Click to hide internal directories.