apiVersion: tekton.dev/v1beta1 kind: Task metadata: name: build-node namespace: tekton-pipelines spec: workspaces: - name: source steps: - name: build image: node:20-bookworm workingDir: $(workspaces.source.path) script: | #!/bin/bash if [ -f ".tekton/build.sh" ]; then echo "Found custom build script. Executing..." /bin/bash .tekton/build.sh else echo "No .tekton/build.sh found! Falling back to default build." npm install npm run build fi