Skip to content

Latest commit

 

History

History
158 lines (122 loc) · 4.83 KB

resources-builds-build.md

File metadata and controls

158 lines (122 loc) · 4.83 KB
title description ms.date monikerRange
resources.builds.build definition
A build resource used to reference artifacts from a run.
06/11/2024
>=azure-pipelines-2019

resources.builds.build definition

:::moniker range=">=azure-pipelines-2019"

A build resource used to reference artifacts from a run.

:::moniker-end

:::moniker range=">=azure-pipelines-2020"

builds:
- build: string # Required as first property. Alias or name of build artifact.
  type: string # Required. Name of the artifact type.
  connection: string # Required. Name of the connection. This connection will be used for all the communication related to this artifact.
  source: string # Required. Name of the source definition/build/job.
  version: string
  branch: string
  trigger: none | true # When the artifact mentioned in this build resource completes a build, it is allowed to trigger this pipeline.

:::moniker-end

:::moniker range=">=azure-pipelines-2019 <=azure-pipelines-2019.1"

builds:
- build: string # Required as first property. Alias or name of build artifact.
  type: string # Required. Name of the artifact type.
  connection: string # Required. Name of the connection. This connection will be used for all the communication related to this artifact.
  source: string # Required. Name of the source definition/build/job.
  version: string
  branch: string

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

Definitions that reference this definition: resources.builds

:::moniker-end

Properties

:::moniker range=">=azure-pipelines-2019"

build string. Required as first property.
Alias or name of build artifact. Acceptable values: [-_A-Za-z0-9]*.

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

type string. Required.
Name of the artifact type.

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

connection string. Required.
Name of the connection. This connection will be used for all the communication related to this artifact.

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

source string. Required.
Name of the source definition/build/job.

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

version string.

:::moniker-end

:::moniker range=">=azure-pipelines-2019"

branch string.

:::moniker-end

:::moniker range=">=azure-pipelines-2020"

trigger string.
When the artifact mentioned in this build resource completes a build, it is allowed to trigger this pipeline. none | true.

:::moniker-end

Remarks

If you have an external CI build system that produces artifacts, you can consume artifacts with a build resource. A build resource can be any external CI systems like Jenkins, TeamCity, CircleCI, and so on.

Important

Triggers are only supported for hosted Jenkins where Azure DevOps has line of sight with Jenkins server.

Examples

resources:
  builds:
  - build: Spaceworkz
    type: Jenkins
    connection: MyJenkinsServer 
    source: SpaceworkzProj   # name of the jenkins source project
    trigger: true

See also

Define resources in YAML