Search code examples
azure-pipelinesazure-pipelines-tasksazure-pipelines-yaml

General timeout argument in azure pipelines


I know how to set a timeout for a specific job in Azure Pipelines. (Jobs documentation here)

Can I set a global definition that will apply to all jobs in that YAML, or do I have to set each one explicitly?


Solution

  • No, we cannot set a global definition that apply to all jobs for the timeout settings in YAML, we have to set the timeout for each of the jobs.

    However, if you are using the same tasks in different jobs, then you can try to create a job template, then reuse this job in your YAML pipeline. Refer to Job reuse for details.