diff --git a/hack/allocate.sh b/hack/allocate.sh index c2dcae3ac..54d13f0f7 100755 --- a/hack/allocate.sh +++ b/hack/allocate.sh @@ -412,18 +412,6 @@ tekton() { $KUBECTL create clusterrolebinding "${namespace}:knative-serving-namespaced-admin" --clusterrole=knative-serving-namespaced-admin --serviceaccount="${namespace}:default" - # TEMPORARY WORKAROUND: Disable affinity assistant to prevent pod scheduling issues - # This is a workaround for issues where affinity assistant pod names don't match - # what's expected by task pods, causing them to fail scheduling. - # Related issues: - # - https://github.com/tektoncd/pipeline/issues/6740 - # - https://github.com/tektoncd/pipeline/issues/7503 - # TODO: Remove this workaround once the underlying Tekton issue is resolved - echo "${blue}- Disabling affinity assistant (temporary workaround)${reset}" - $KUBECTL patch configmap feature-flags -n tekton-pipelines \ - -p '{"data":{"disable-affinity-assistant":"true", "coschedule":"disabled"}}' \ - --type=merge - echo "${green}✅ Tekton${reset}" } diff --git a/pkg/pipelines/tekton/tasks.go b/pkg/pipelines/tekton/tasks.go index 4a9c58490..b21fe1cc4 100644 --- a/pkg/pipelines/tekton/tasks.go +++ b/pkg/pipelines/tekton/tasks.go @@ -416,6 +416,12 @@ spec: workspaces: - name: source description: The workspace containing the function project + - name: cache + optional: true + - name: sslcertdir + optional: true + - name: dockerconfig + optional: true steps: - name: func-deploy image: "%s" @@ -443,6 +449,12 @@ spec: workspaces: - name: source description: The workspace containing the function project + - name: cache + optional: true + - name: sslcertdir + optional: true + - name: dockerconfig + optional: true steps: - name: func-scaffold image: %s diff --git a/pkg/pipelines/tekton/templates_pack.go b/pkg/pipelines/tekton/templates_pack.go index e9ab0e395..f38c39d36 100644 --- a/pkg/pipelines/tekton/templates_pack.go +++ b/pkg/pipelines/tekton/templates_pack.go @@ -49,6 +49,10 @@ spec: workspaces: - name: source workspace: source-workspace + - name: cache + workspace: cache-workspace + - name: dockerconfig + workspace: dockerconfig-workspace {{.RunAfterFetchSources}} {{.FuncScaffoldTaskRef}} - name: build @@ -86,6 +90,10 @@ spec: workspaces: - name: source workspace: source-workspace + - name: cache + workspace: cache-workspace + - name: dockerconfig + workspace: dockerconfig-workspace workspaces: - description: Directory where function source is located. name: source-workspace diff --git a/pkg/pipelines/tekton/templates_s2i.go b/pkg/pipelines/tekton/templates_s2i.go index 7315a382b..2c4c53a6f 100644 --- a/pkg/pipelines/tekton/templates_s2i.go +++ b/pkg/pipelines/tekton/templates_s2i.go @@ -53,6 +53,10 @@ spec: workspaces: - name: source workspace: source-workspace + - name: cache + workspace: cache-workspace + - name: dockerconfig + workspace: dockerconfig-workspace {{.RunAfterFetchSources}} {{.FuncScaffoldTaskRef}} - name: build @@ -92,6 +96,10 @@ spec: workspaces: - name: source workspace: source-workspace + - name: cache + workspace: cache-workspace + - name: dockerconfig + workspace: dockerconfig-workspace workspaces: - description: Directory where function source is located. name: source-workspace