operator

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 28, 2019 License: Apache-2.0 Imports: 34 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// ClusterConfigNamespace is the namespace containing the cluster config
	ClusterConfigNamespace = "kube-system"
	// ClusterConfigName is the name of the cluster config configmap
	ClusterConfigName = "cluster-config-v1"
	// InstallConfigKey is the key in the cluster config configmap containing yaml installConfig data
	InstallConfigKey = "install-config"
	// AWSPlatformType is used to install on AWS
	AWSProvider = Provider("aws")
	// LibvirtPlatformType is used to install of libvirt
	LibvirtProvider = Provider("libvirt")
	// OpenStackPlatformType is used to install on OpenStack
	OpenStackProvider = Provider("openstack")
)

Variables

This section is empty.

Functions

func ApplyClusterOperator added in v0.2.0

ApplyClusterOperator applies the required ClusterOperator

func PopulateTemplate added in v0.2.0

func PopulateTemplate(config *OperatorConfig, path string) ([]byte, error)

PopulateTemplate receives a template file path and renders its content populated with the config

Types

type Controllers added in v0.2.0

type Controllers struct {
	Provider           string
	NodeLink           string
	MachineHealthCheck string
}

type Images added in v0.2.0

type Images struct {
	MachineAPIOperator            string `json:"machineAPIOperator"`
	ClusterAPIControllerAWS       string `json:"clusterAPIControllerAWS"`
	ClusterAPIControllerOpenStack string `json:"clusterAPIControllerOpenStack"`
	ClusterAPIControllerLibvirt   string `json:"clusterAPIControllerLibvirt"`
}

Images allows build systems to inject images for MAO components

type InstallConfig added in v0.2.0

type InstallConfig struct {
	InstallPlatform `json:"platform"`
}

InstallConfig contains the mao relevant config coming from the install config, i.e provider

type InstallPlatform added in v0.2.0

type InstallPlatform struct {
	// AWS is the configuration used when running on AWS
	AWS interface{} `json:"aws,omitempty"`

	// Libvirt is the configuration used when running on libvirt
	Libvirt interface{} `json:"libvirt,omitempty"`

	// OpenStack is the configuration used when running on OpenStack
	OpenStack interface{} `json:"openstack,omitempty"`
}

InstallPlatform is the configuration for the specific platform upon which to perform the installation. Only one of the platform configuration should be set

type Operator

type Operator struct {
	// contains filtered or unexported fields
}

Operator defines machine api operator.

func New

func New(
	namespace, name string,
	imagesFile string,

	config string,

	serviceAccountInfomer coreinformersv1.ServiceAccountInformer,
	deployInformer appsinformersv1.DeploymentInformer,
	clusterRoleInformer rbacinformersv1.ClusterRoleInformer,
	clusterRoleBindingInformer rbacinformersv1.ClusterRoleBindingInformer,

	kubeClient kubernetes.Interface,
	osClient osclientset.Interface,
) *Operator

New returns a new machine config operator.

func (*Operator) Run

func (optr *Operator) Run(workers int, stopCh <-chan struct{})

Run runs the machine config operator.

type OperatorConfig added in v0.2.0

type OperatorConfig struct {
	TargetNamespace string `json:"targetNamespace"`
	Controllers     Controllers
}

OperatorConfig contains configuration for MAO

type Provider added in v0.2.0

type Provider string

type StatusReason added in v0.2.0

type StatusReason string

StatusReason is a MixedCaps string representing the reason for a status condition change.

const (
	ReasonEmpty      StatusReason = ""
	ReasonSyncing    StatusReason = "SyncingResources"
	ReasonSyncFailed StatusReason = "SyncingFailed"
)

The default set of status change reasons.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL