resourceapply

package
v0.0.0-...-a45fa12 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2019 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const CreateOnlyAnnotation = "release.openshift.io/create-only"

CreateOnlyAnnotation means that this resource should be created if it does not exist, but should not be updated if it already exists. It is uniformly respected across all resources, but the first known use-cases are for empty config.openshift.io and initial low-level operator resources. Set .metadata.annotations["release.openshift.io/create-only"]="true" to have a create-only resource.

Variables

This section is empty.

Functions

func ApplyClusterRole

func ApplyClusterRole(client rbacclientv1.ClusterRolesGetter, required *rbacv1.ClusterRole) (*rbacv1.ClusterRole, bool, error)

ApplyClusterRole applies the required clusterrole to the cluster.

func ApplyClusterRoleBinding

ApplyClusterRoleBinding applies the required clusterrolebinding to the cluster.

func ApplyConfigMap

func ApplyConfigMap(client coreclientv1.ConfigMapsGetter, required *corev1.ConfigMap) (*corev1.ConfigMap, bool, error)

ApplyConfigMap applies the required serviceaccount to the cluster.

func ApplyDaemonSet

func ApplyDaemonSet(client appsclientv1.DaemonSetsGetter, required *appsv1.DaemonSet) (*appsv1.DaemonSet, bool, error)

ApplyDaemonSet applies the required daemonset to the cluster.

func ApplyDaemonSetFromCache

func ApplyDaemonSetFromCache(lister appslisterv1.DaemonSetLister, client appsclientv1.DaemonSetsGetter, required *appsv1.DaemonSet) (*appsv1.DaemonSet, bool, error)

ApplyDaemonSetFromCache applies the required deployment to the cluster.

func ApplyDeployment

func ApplyDeployment(client appsclientv1.DeploymentsGetter, required *appsv1.Deployment) (*appsv1.Deployment, bool, error)

ApplyDeployment applies the required deployment to the cluster.

func ApplyDeploymentFromCache

func ApplyDeploymentFromCache(lister appslisterv1.DeploymentLister, client appsclientv1.DeploymentsGetter, required *appsv1.Deployment) (*appsv1.Deployment, bool, error)

ApplyDeploymentFromCache applies the required deployment to the cluster.

func ApplyJob

func ApplyJob(client batchclientv1.JobsGetter, required *batchv1.Job) (*batchv1.Job, bool, error)

ApplyJob applies the required Job to the cluster.

func ApplyNamespace

func ApplyNamespace(client coreclientv1.NamespacesGetter, required *corev1.Namespace) (*corev1.Namespace, bool, error)

ApplyNamespace merges objectmeta, does not worry about anything else

func ApplyRole

func ApplyRole(client rbacclientv1.RolesGetter, required *rbacv1.Role) (*rbacv1.Role, bool, error)

ApplyRole applies the required clusterrole to the cluster.

func ApplyRoleBinding

func ApplyRoleBinding(client rbacclientv1.RoleBindingsGetter, required *rbacv1.RoleBinding) (*rbacv1.RoleBinding, bool, error)

ApplyRoleBinding applies the required clusterrolebinding to the cluster.

func ApplySecurityContextConstraints

ApplySecurityContextConstraints applies the required SecurityContextConstraints to the cluster.

func ApplyService

func ApplyService(client coreclientv1.ServicesGetter, required *corev1.Service) (*corev1.Service, bool, error)

ApplyService merges objectmeta and requires TODO, since this cannot determine whether changes are due to legitimate actors (api server) or illegitimate ones (users), we cannot update TODO I've special cased the selector for now

func ApplyServiceAccount

func ApplyServiceAccount(client coreclientv1.ServiceAccountsGetter, required *corev1.ServiceAccount) (*corev1.ServiceAccount, bool, error)

ApplyServiceAccount applies the required serviceaccount to the cluster.

func IsCreateOnly

func IsCreateOnly(metadata metav1.Object) bool

IsCreateOnly takes metadata and returns true if the resource should only be created, not updated.

Types

This section is empty.

Jump to

Keyboard shortcuts

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