apiVersion: tekton.dev/v1alpha1
kind: TaskRun
metadata:
  generateName: template-volume-
spec:
  taskSpec:
    steps:
    - name: write
      image: ubuntu
      script: |
        #!/usr/bin/env bash
        echo some stuff > /im/a/custom/mount/path/file
      volumeMounts:
      - name: custom
        mountPath: /im/a/custom/mount/path
    - name: read
      image: ubuntu
      script: |
        #!/usr/bin/env bash
        cat /short/and/stout/file
      volumeMounts:
      - name: custom
        mountPath: /short/and/stout
  podTemplate:
    volumes:
    - name: custom
      emptyDir: {}
