Documentation
¶
Index ¶
- Constants
- func AddAnnotations(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, ...) error
- func AddRetry(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, ...) error
- func CreateAnnotationsPatch(newAnnotations map[string]string, obj objects.TektonObject) ([]byte, error)
- func HandleRetry(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, ...) error
- func MarkFailed(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, ...) error
- func MarkSigned(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, ...) error
- func Reconciled(ctx context.Context, client versioned.Interface, obj objects.TektonObject) bool
- func RetryAvailable(obj objects.TektonObject) bool
Constants ¶
View Source
const ( // ChainsAnnotationPrefix is the prefix for all Chains annotations ChainsAnnotationPrefix = "chains.tekton.dev/" ChainsAnnotation = ChainsAnnotationPrefix + "signed" RetryAnnotation = ChainsAnnotationPrefix + "retries" ChainsTransparencyAnnotation = ChainsAnnotationPrefix + "transparency" MaxRetries = 3 )
Variables ¶
This section is empty.
Functions ¶
func AddAnnotations ¶
func AddAnnotations(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, annotations map[string]string) error
AddAnnotations adds annotation to the k8s object
func CreateAnnotationsPatch ¶
func CreateAnnotationsPatch(newAnnotations map[string]string, obj objects.TektonObject) ([]byte, error)
CreateAnnotationsPatch returns patch bytes that can be used with kubectl patch
func HandleRetry ¶
func HandleRetry(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, annotationsMap map[string]string) error
HandleRetry handles retries managed as annotation on the k8s object
func MarkFailed ¶
func MarkSigned ¶
func MarkSigned(ctx context.Context, obj objects.TektonObject, ps versioned.Interface, annotations map[string]string) error
MarkSigned marks a Tekton object as signed.
func Reconciled ¶
Reconciled determines whether a Tekton object has already been reconciled. It first inspects the state of the given TektonObject. If that indicates it has not been reconciled, then Reconciled fetches the latest version of the TektonObject from the cluster and inspects that version as well. This aims to avoid creating multiple attestations due to a stale cached TektonObject.
func RetryAvailable ¶
func RetryAvailable(obj objects.TektonObject) bool
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.