jobs definition
Specifies the jobs that make up the work of a stage.
Specifies the jobs that make up the work of a pipeline.
jobs: [ job | deployment | template ] # Specifies the jobs that make up the work of a stage.
jobs: [ job ] # Specifies the jobs that make up the work of a pipeline.
Definitions that reference this definition: pipeline, stages.stage
Definitions that reference this definition: pipeline
List types
Type | Description |
---|---|
jobs.job | A job is a collection of steps run by an agent or on a server. |
jobs.deployment | A deployment job is a special type of job. It's a collection of steps to run sequentially against the environment. |
jobs.template | A set of jobs defined in a template. |
Type | Description |
---|---|
jobs.job | A job is a collection of steps run by an agent or on a server. |
Remarks
A job is a collection of steps run by an agent or on a server. Jobs can run conditionally and might depend on earlier jobs.
Note
If you have only one stage and one job, you can use single-job syntax as a shorter way to describe the steps to run.
Examples
jobs:
- job: MyJob
displayName: My First Job
continueOnError: true
workspace:
clean: outputs
steps:
- script: echo My first job
See also
- For more information about
uses
, see Limit job authorization scope to referenced Azure DevOps repositories. For more information about workspaces, including clean options, see the workspace topic in Jobs. - Learn more about variables, steps, pools, and server jobs.