Documentation ¶
Overview ¶
Copyright © 2019 Banzai Cloud
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- func ApplyResources(client k8sclient.Client, labelManager LabelManager, objects object.K8sObjects, ...) (object.K8sObjects, error)
- func CRDEstablishedConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
- func ConvertRuntimeObjectToK8sObjects(objects []runtime.Object) (object.K8sObjects, error)
- func DeleteResources(client k8sclient.Client, labelManager LabelManager, objects object.K8sObjects, ...) (object.K8sObjects, error)
- func ExistsConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
- func GetFormattedName(object Object) string
- func GetFormattedName2(object runtime.Object) string
- func GetTokenForServiceAccountName(client k8sclient.Client, key types.NamespacedName) (string, error)
- func NonExistsConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
- func ReadyReplicasConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
- func WaitForResourcesConditions(client k8sclient.Client, objects []NamespacedNameWithGVK, backoff wait.Backoff, ...) error
- type LabelManager
- type NamespacedNameWithGVK
- type Object
- type PostResourceApplyFunc
- type PostResourceDeleteFunc
- type ResourceConditionCheck
- type WaitForResourceConditionsFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyResources ¶
func ApplyResources(client k8sclient.Client, labelManager LabelManager, objects object.K8sObjects, log logger.Logger, waitFuncs ...WaitForResourceConditionsFunc) (object.K8sObjects, error)
func CRDEstablishedConditionCheck ¶
func CRDEstablishedConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
func ConvertRuntimeObjectToK8sObjects ¶
func ConvertRuntimeObjectToK8sObjects(objects []runtime.Object) (object.K8sObjects, error)
func DeleteResources ¶
func DeleteResources(client k8sclient.Client, labelManager LabelManager, objects object.K8sObjects, log logger.Logger, waitFuncs ...WaitForResourceConditionsFunc) (object.K8sObjects, error)
func ExistsConditionCheck ¶
func ExistsConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
func GetFormattedName ¶
func GetFormattedName2 ¶
func GetTokenForServiceAccountName ¶
func GetTokenForServiceAccountName(client k8sclient.Client, key types.NamespacedName) (string, error)
GetTokenForServiceAccountName retrieves an auth token of service account from the related secret
func NonExistsConditionCheck ¶
func NonExistsConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
func ReadyReplicasConditionCheck ¶
func ReadyReplicasConditionCheck(obj *unstructured.Unstructured, k8serror error) bool
func WaitForResourcesConditions ¶
func WaitForResourcesConditions(client k8sclient.Client, objects []NamespacedNameWithGVK, backoff wait.Backoff, log logger.Logger, checkFuncs ...ResourceConditionCheck) error
Types ¶
type LabelManager ¶
type NamespacedNameWithGVK ¶
type NamespacedNameWithGVK struct { types.NamespacedName schema.GroupVersionKind }
func NamesWithGVKFromK8sObjects ¶
func NamesWithGVKFromK8sObjects(objects object.K8sObjects, kind ...string) []NamespacedNameWithGVK
func (NamespacedNameWithGVK) String ¶
func (o NamespacedNameWithGVK) String() string
func (NamespacedNameWithGVK) Unstructured ¶
func (o NamespacedNameWithGVK) Unstructured() *unstructured.Unstructured
type ResourceConditionCheck ¶
type ResourceConditionCheck func(*unstructured.Unstructured, error) bool
type WaitForResourceConditionsFunc ¶
type WaitForResourceConditionsFunc func(k8sclient.Client, *unstructured.Unstructured) error
func WaitForResourceConditions ¶
func WaitForResourceConditions(backoff wait.Backoff, log logger.Logger, checkFuncs ...ResourceConditionCheck) WaitForResourceConditionsFunc
Click to show internal directories.
Click to hide internal directories.