Skip to content

TEP-0056: Pipelines in Pipelines. Fine-grained timeout overrides for child PipelineRuns. #10181

Description

@twoGiants

Feature request

Add a pipelineRunSpecs field to PipelineRunSpec (alongside the existing taskRunSpecs) to provide fine-grained timeout control for child PipelineRuns. This enables setting timeouts.pipeline, timeouts.tasks and timeouts.finally independently on a per-child basis.

pipelineRunSpecs follows the same pattern as taskRunSpecs:

  • taskRunSpecs takes a list of PipelineTaskRunSpec to configure how a Task in a Pipeline is run
  • pipelineRunSpecs takes a list of ChildPipelineRunSpec to configure how a child Pipeline in a Pipeline is run

ChildPipelineRunSpec contains a PipelineTaskName identifying which PipelineTask the configuration applies to, and a Timeouts field with the fine-grained timeout settings.

This includes:

  • Add pipelineRunSpecs field and ChildPipelineRunSpec type to the API
  • Apply the specified timeouts when creating child PipelineRuns
  • Update docs/pipelines-in-pipelines.md documentation

See TEP-0056: Runtime specification - provide overrides for PipelineRun.

Use case

A parent PipelineRun needs fine-grained timeout control over a child Pipeline that runs security scans, allocating separate budgets for tasks and finally tasks:

apiVersion: tekton.dev/v1
kind: PipelineRun
metadata:
  name: clone-scan-notify-run
spec:
  pipelineRef:
    name: clone-scan-notify
  pipelineRunSpecs:
    - pipelineTaskName: security-scans
      timeouts:
        pipeline: "0h0m60s"
        tasks: "0h0m40s"
        finally: "0h0m20s"

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/featureCategorizes issue or PR as related to a new feature.

    Projects

    Status
    Todo
    Status
    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions