Documentation ¶
Index ¶
- func GetConditionByRef(refs []corev1.ObjectReference, msg string, status kptv1.ConditionStatus, ...) (kptv1.Condition, error)
- func GetConditionType(o *corev1.ObjectReference) string
- func GetGVKNFromConditionType(ct string) (o *corev1.ObjectReference)
- type KptFile
- func (r *KptFile) DeleteCondition(ct string) error
- func (r *KptFile) DeleteConditionRef(ref corev1.ObjectReference) error
- func (r *KptFile) GetCondition(conditionType string) *kptv1.Condition
- func (r *KptFile) GetConditions() []kptv1.Condition
- func (r *KptFile) GetReadinessGates() []kptv1.ReadinessGate
- func (r *KptFile) HasReadinessGate(ct string) bool
- func (r *KptFile) IsReady(ctPrefix string) bool
- func (r *KptFile) SetConditionRefFailed(ref corev1.ObjectReference, msg string) error
- func (r *KptFile) SetConditions(ncs ...kptv1.Condition) error
- func (r *KptFile) SetReadinessGates(cs ...string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetConditionByRef ¶
func GetConditionByRef(refs []corev1.ObjectReference, msg string, status kptv1.ConditionStatus, ec *kptv1.Condition) (kptv1.Condition, error)
func GetConditionType ¶
func GetConditionType(o *corev1.ObjectReference) string
GetConditionType returns a string based on the KRM object Reference It acts on APIVersion, Kind and Name. if these parameters don't exist the string does not contain these parameters
func GetGVKNFromConditionType ¶
func GetGVKNFromConditionType(ct string) (o *corev1.ObjectReference)
GetGVKNFromConditionType return a KRM ObjectReference from a string It expects an APIVersion with a / as a.b/c and a kind + name if not it returns an empty ObjectReference
Types ¶
type KptFile ¶
type KptFile struct {
Kptfile *fn.KubeObject
}
func (*KptFile) DeleteCondition ¶
DeleteCondition deletes the conditions from the list with a given type
func (*KptFile) DeleteConditionRef ¶
func (r *KptFile) DeleteConditionRef(ref corev1.ObjectReference) error
func (*KptFile) GetCondition ¶
Get returns with the condition whose type is `conditionType` as its first return value, and whether the component exists or not as its second return value
func (*KptFile) GetConditions ¶
GetConditions returns with (a copy of) the list of current conditions of the kpt package
func (*KptFile) GetReadinessGates ¶
func (r *KptFile) GetReadinessGates() []kptv1.ReadinessGate
func (*KptFile) HasReadinessGate ¶
func (*KptFile) SetConditionRefFailed ¶
func (r *KptFile) SetConditionRefFailed(ref corev1.ObjectReference, msg string) error
func (*KptFile) SetConditions ¶
SetConditions overwrites the existing condition or append the condition to the list if it does not exist