Documentation ¶
Overview ¶
Package cleanup for clean pvc mount for taskrun
Index ¶
Constants ¶
View Source
const ( // PVCFinalizersForPod Finalizers in pvc about pod PVCFinalizersForPod = "kubernetes.io/pvc-protection" // ConditionCleanup is triggered when doing GC ConditionCleanup = "Cleanup" )
Variables ¶
This section is empty.
Functions ¶
func CleanTaskRunsPVC ¶
func CleanTaskRunsPVC(ctx context.Context, taskLables client.MatchingLabels, shouldSkip ShouldSkipCleanup, ) (succeeded []types.NamespacedName, fails map[string]error, err error)
CleanTaskRunsPVC clean taskrun workspace pvc that dynamic create Params: taskLabels for filt taskrun with label, maybe is empty shouldSkip for skip clean Results: succeeded, fails indicate clean pvc successful and failed list
func IsVolumeShouldSkip ¶
func IsVolumeShouldSkip(workspaces []tekton.WorkspaceBinding, v tekton.WorkspaceBinding) bool
IsVolumeShouldSkip indicates if the pvc is nil or created by manual should skip clean
Types ¶
type ShouldSkipCleanup ¶
type ShouldSkipCleanup func(ctx context.Context, workspace tekton.WorkspaceBinding) bool
Click to show internal directories.
Click to hide internal directories.