resources.builds.build 定义

用于引用运行中的项目的生成资源。

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.

引用此定义的定义:resources.builds

性能

build 字符串。 必需为第一个属性。
生成项目的别名或名称。 可接受的值:[-_A-Za-z0-9]*。

type 字符串。 必填。
项目类型的名称。

connection 字符串。 必填。
连接的名称。 此连接将用于与此项目相关的所有通信。

source 字符串。 必填。
源定义/生成/作业的名称。

version 字符串。

branch 字符串。

trigger 字符串。
当此生成资源中提到的项目完成生成时,可以触发此管道。 none |真。

注解

如果有生成项目的外部 CI 生成系统,则可以使用生成资源的项目。 生成资源可以是任何外部 CI 系统,例如 Jenkins、TeamCity、CircleCI 等。

重要

仅托管的 Jenkins 支持触发器,其中 Azure DevOps 与 Jenkins 服务器具有视线。

例子

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

另请参阅

在 YAML 中定义资源