共用方式為


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 中定義資源