Skip to content

Latest commit

 

History

History
203 lines (166 loc) · 6.01 KB

resources-containers-container-trigger.md

File metadata and controls

203 lines (166 loc) · 6.01 KB
title description ms.date monikerRange
resources.containers.container.trigger definition
Specify none to disable, true to trigger on all image tags, or use the full syntax as described in the following examples.
10/04/2024
>=azure-pipelines-2020

resources.containers.container.trigger definition

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

Specifies the trigger conditions for a container resource.

:::moniker-end

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

Definitions that reference this definition: resources.containers.container

:::moniker-end

Implementations

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

Implementation Description
trigger: enabled, tags Specify a list of tags to trigger on.
[trigger: none true](#triggerstring)

:::moniker-end

Remarks

Specify none to disable, true to trigger on all image tags, or use the full syntax as described in the following examples.

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

trigger: enabled, tags

Configure which tags trigger a run.

trigger:
  enabled: boolean # Whether the trigger is enabled; defaults to true.
  tags: includeExcludeStringFilters | [ string ] # Tag names to include or exclude for triggering a run.

Properties

enabled boolean.
Whether the trigger is enabled; defaults to true.

tags includeExcludeStringFilters.
Tag names to include or exclude for triggering a run.

:::moniker-end

Examples

In the following example, the trigger is enabled for tags matching production*.

resources:         
  containers:
  - container: petStore      
    type: ACR  
    azureSubscription: ContosoARMConnection
    resourceGroup: ContosoGroup
    registry: petStoreRegistry
    repository: myPets
    trigger: 
      tags:
        include: 
        - production*

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

trigger: none | true

Specify none to disable or true to trigger on all image tags.

trigger: none | true # Specify none to disable or true to trigger on all image tags.

trigger string. Allowed values: none | true.

Specify none to disable or true to trigger on all image tags.

:::moniker-end

Remarks

Specify none to disable the trigger, or true to enable. If not specified, the default is none. To configure triggers based on specific tags, see the following section.

Examples

resources:         
  containers:
  - container: petStore      
    type: ACR  
    azureSubscription: ContosoARMConnection
    resourceGroup: ContosoGroup
    registry: petStoreRegistry
    repository: myPets
    trigger: 
      tags: none # Triggers disabled
resources:         
  containers:
  - container: petStore      
    type: ACR  
    azureSubscription: ContosoARMConnection
    resourceGroup: ContosoGroup
    registry: petStoreRegistry
    repository: myPets
    trigger: 
      tags: true # Triggers enabled for all tags

See also