Documentation ¶
Index ¶
Constants ¶
View Source
const ( // DefaultWatchNamespace is the default namespace the operator // will watch for instances of its custom resources. DefaultWatchNamespace = "openshift-cluster-api" // DefaultClusterAutoscalerNamespace is the default namespace for // cluster-autoscaler deployments. DefaultClusterAutoscalerNamespace = "openshift-cluster-api" // DefaultClusterAutoscalerName is the default ClusterAutoscaler // object watched by the operator. DefaultClusterAutoscalerName = "default" // DefaultClusterAutoscalerImage is the default image used in // ClusterAutoscaler deployments. DefaultClusterAutoscalerImage = "quay.io/openshift/origin-cluster-autoscaler:v4.0" // DefaultClusterAutoscalerReplicas is the default number of // replicas in ClusterAutoscaler deployments. DefaultClusterAutoscalerReplicas = 1 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // WatchNamespace is the namespace the operator will watch for // ClusterAutoscaler and MachineAutoscaler instances. WatchNamespace string // ClusterAutoscalerNamespace is the namespace in which // cluster-autoscaler deployments will be created. ClusterAutoscalerNamespace string // ClusterAutoscalerName is the name of the ClusterAutoscaler // resource that will be watched by the operator. ClusterAutoscalerName string // ClusterAutoscalerImage is the image to be used in // ClusterAutoscaler deployments. ClusterAutoscalerImage string // ClusterAutoscalerReplicas is the number of replicas to be // configured in ClusterAutoscaler deployments. ClusterAutoscalerReplicas int32 }
Config represents the runtime configuration for the operator.
func ConfigFromEnvironment ¶
func ConfigFromEnvironment() *Config
ConfigFromEnvironment returns a new Config object with defaults overridden by environment variables when set.
type Operator ¶
type Operator struct {
// contains filtered or unexported fields
}
Operator represents an instance of the cluster-autoscaler-operator.
func New ¶
New returns a new Operator instance with the given config and a manager configured with the various controllers.
func (*Operator) AddControllers ¶
AddControllers configures the various controllers and adds them to the operator's manager instance.
Click to show internal directories.
Click to hide internal directories.