1. Packages
  2. Azure DevOps Provider
  3. API Docs
  4. BranchPolicyCommentResolution
Azure DevOps v3.8.0 published on Monday, Mar 17, 2025 by Pulumi

azuredevops.BranchPolicyCommentResolution

Explore with Pulumi AI

Configure a comment resolution policy for your branch within Azure DevOps project.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as azuredevops from "@pulumi/azuredevops";

const example = new azuredevops.Project("example", {name: "Example Project"});
const exampleGit = new azuredevops.Git("example", {
    projectId: example.id,
    name: "Example Repository",
    initialization: {
        initType: "Clean",
    },
});
const exampleBranchPolicyCommentResolution = new azuredevops.BranchPolicyCommentResolution("example", {
    projectId: example.id,
    enabled: true,
    blocking: true,
    settings: {
        scopes: [
            {
                repositoryId: exampleGit.id,
                repositoryRef: exampleGit.defaultBranch,
                matchType: "Exact",
            },
            {
                repositoryId: exampleGit.id,
                repositoryRef: "refs/heads/releases",
                matchType: "Prefix",
            },
            {
                matchType: "DefaultBranch",
            },
        ],
    },
});
Copy
import pulumi
import pulumi_azuredevops as azuredevops

example = azuredevops.Project("example", name="Example Project")
example_git = azuredevops.Git("example",
    project_id=example.id,
    name="Example Repository",
    initialization={
        "init_type": "Clean",
    })
example_branch_policy_comment_resolution = azuredevops.BranchPolicyCommentResolution("example",
    project_id=example.id,
    enabled=True,
    blocking=True,
    settings={
        "scopes": [
            {
                "repository_id": example_git.id,
                "repository_ref": example_git.default_branch,
                "match_type": "Exact",
            },
            {
                "repository_id": example_git.id,
                "repository_ref": "refs/heads/releases",
                "match_type": "Prefix",
            },
            {
                "match_type": "DefaultBranch",
            },
        ],
    })
Copy
package main

import (
	"github.com/pulumi/pulumi-azuredevops/sdk/v3/go/azuredevops"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := azuredevops.NewProject(ctx, "example", &azuredevops.ProjectArgs{
			Name: pulumi.String("Example Project"),
		})
		if err != nil {
			return err
		}
		exampleGit, err := azuredevops.NewGit(ctx, "example", &azuredevops.GitArgs{
			ProjectId: example.ID(),
			Name:      pulumi.String("Example Repository"),
			Initialization: &azuredevops.GitInitializationArgs{
				InitType: pulumi.String("Clean"),
			},
		})
		if err != nil {
			return err
		}
		_, err = azuredevops.NewBranchPolicyCommentResolution(ctx, "example", &azuredevops.BranchPolicyCommentResolutionArgs{
			ProjectId: example.ID(),
			Enabled:   pulumi.Bool(true),
			Blocking:  pulumi.Bool(true),
			Settings: &azuredevops.BranchPolicyCommentResolutionSettingsArgs{
				Scopes: azuredevops.BranchPolicyCommentResolutionSettingsScopeArray{
					&azuredevops.BranchPolicyCommentResolutionSettingsScopeArgs{
						RepositoryId:  exampleGit.ID(),
						RepositoryRef: exampleGit.DefaultBranch,
						MatchType:     pulumi.String("Exact"),
					},
					&azuredevops.BranchPolicyCommentResolutionSettingsScopeArgs{
						RepositoryId:  exampleGit.ID(),
						RepositoryRef: pulumi.String("refs/heads/releases"),
						MatchType:     pulumi.String("Prefix"),
					},
					&azuredevops.BranchPolicyCommentResolutionSettingsScopeArgs{
						MatchType: pulumi.String("DefaultBranch"),
					},
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureDevOps = Pulumi.AzureDevOps;

return await Deployment.RunAsync(() => 
{
    var example = new AzureDevOps.Project("example", new()
    {
        Name = "Example Project",
    });

    var exampleGit = new AzureDevOps.Git("example", new()
    {
        ProjectId = example.Id,
        Name = "Example Repository",
        Initialization = new AzureDevOps.Inputs.GitInitializationArgs
        {
            InitType = "Clean",
        },
    });

    var exampleBranchPolicyCommentResolution = new AzureDevOps.BranchPolicyCommentResolution("example", new()
    {
        ProjectId = example.Id,
        Enabled = true,
        Blocking = true,
        Settings = new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsArgs
        {
            Scopes = new[]
            {
                new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsScopeArgs
                {
                    RepositoryId = exampleGit.Id,
                    RepositoryRef = exampleGit.DefaultBranch,
                    MatchType = "Exact",
                },
                new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsScopeArgs
                {
                    RepositoryId = exampleGit.Id,
                    RepositoryRef = "refs/heads/releases",
                    MatchType = "Prefix",
                },
                new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsScopeArgs
                {
                    MatchType = "DefaultBranch",
                },
            },
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azuredevops.Project;
import com.pulumi.azuredevops.ProjectArgs;
import com.pulumi.azuredevops.Git;
import com.pulumi.azuredevops.GitArgs;
import com.pulumi.azuredevops.inputs.GitInitializationArgs;
import com.pulumi.azuredevops.BranchPolicyCommentResolution;
import com.pulumi.azuredevops.BranchPolicyCommentResolutionArgs;
import com.pulumi.azuredevops.inputs.BranchPolicyCommentResolutionSettingsArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new Project("example", ProjectArgs.builder()
            .name("Example Project")
            .build());

        var exampleGit = new Git("exampleGit", GitArgs.builder()
            .projectId(example.id())
            .name("Example Repository")
            .initialization(GitInitializationArgs.builder()
                .initType("Clean")
                .build())
            .build());

        var exampleBranchPolicyCommentResolution = new BranchPolicyCommentResolution("exampleBranchPolicyCommentResolution", BranchPolicyCommentResolutionArgs.builder()
            .projectId(example.id())
            .enabled(true)
            .blocking(true)
            .settings(BranchPolicyCommentResolutionSettingsArgs.builder()
                .scopes(                
                    BranchPolicyCommentResolutionSettingsScopeArgs.builder()
                        .repositoryId(exampleGit.id())
                        .repositoryRef(exampleGit.defaultBranch())
                        .matchType("Exact")
                        .build(),
                    BranchPolicyCommentResolutionSettingsScopeArgs.builder()
                        .repositoryId(exampleGit.id())
                        .repositoryRef("refs/heads/releases")
                        .matchType("Prefix")
                        .build(),
                    BranchPolicyCommentResolutionSettingsScopeArgs.builder()
                        .matchType("DefaultBranch")
                        .build())
                .build())
            .build());

    }
}
Copy
resources:
  example:
    type: azuredevops:Project
    properties:
      name: Example Project
  exampleGit:
    type: azuredevops:Git
    name: example
    properties:
      projectId: ${example.id}
      name: Example Repository
      initialization:
        initType: Clean
  exampleBranchPolicyCommentResolution:
    type: azuredevops:BranchPolicyCommentResolution
    name: example
    properties:
      projectId: ${example.id}
      enabled: true
      blocking: true
      settings:
        scopes:
          - repositoryId: ${exampleGit.id}
            repositoryRef: ${exampleGit.defaultBranch}
            matchType: Exact
          - repositoryId: ${exampleGit.id}
            repositoryRef: refs/heads/releases
            matchType: Prefix
          - matchType: DefaultBranch
Copy

Create BranchPolicyCommentResolution Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new BranchPolicyCommentResolution(name: string, args: BranchPolicyCommentResolutionArgs, opts?: CustomResourceOptions);
@overload
def BranchPolicyCommentResolution(resource_name: str,
                                  args: BranchPolicyCommentResolutionArgs,
                                  opts: Optional[ResourceOptions] = None)

@overload
def BranchPolicyCommentResolution(resource_name: str,
                                  opts: Optional[ResourceOptions] = None,
                                  project_id: Optional[str] = None,
                                  settings: Optional[BranchPolicyCommentResolutionSettingsArgs] = None,
                                  blocking: Optional[bool] = None,
                                  enabled: Optional[bool] = None)
func NewBranchPolicyCommentResolution(ctx *Context, name string, args BranchPolicyCommentResolutionArgs, opts ...ResourceOption) (*BranchPolicyCommentResolution, error)
public BranchPolicyCommentResolution(string name, BranchPolicyCommentResolutionArgs args, CustomResourceOptions? opts = null)
public BranchPolicyCommentResolution(String name, BranchPolicyCommentResolutionArgs args)
public BranchPolicyCommentResolution(String name, BranchPolicyCommentResolutionArgs args, CustomResourceOptions options)
type: azuredevops:BranchPolicyCommentResolution
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. BranchPolicyCommentResolutionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. BranchPolicyCommentResolutionArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. BranchPolicyCommentResolutionArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. BranchPolicyCommentResolutionArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. BranchPolicyCommentResolutionArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var branchPolicyCommentResolutionResource = new AzureDevOps.BranchPolicyCommentResolution("branchPolicyCommentResolutionResource", new()
{
    ProjectId = "string",
    Settings = new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsArgs
    {
        Scopes = new[]
        {
            new AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsScopeArgs
            {
                MatchType = "string",
                RepositoryId = "string",
                RepositoryRef = "string",
            },
        },
    },
    Blocking = false,
    Enabled = false,
});
Copy
example, err := azuredevops.NewBranchPolicyCommentResolution(ctx, "branchPolicyCommentResolutionResource", &azuredevops.BranchPolicyCommentResolutionArgs{
	ProjectId: pulumi.String("string"),
	Settings: &azuredevops.BranchPolicyCommentResolutionSettingsArgs{
		Scopes: azuredevops.BranchPolicyCommentResolutionSettingsScopeArray{
			&azuredevops.BranchPolicyCommentResolutionSettingsScopeArgs{
				MatchType:     pulumi.String("string"),
				RepositoryId:  pulumi.String("string"),
				RepositoryRef: pulumi.String("string"),
			},
		},
	},
	Blocking: pulumi.Bool(false),
	Enabled:  pulumi.Bool(false),
})
Copy
var branchPolicyCommentResolutionResource = new BranchPolicyCommentResolution("branchPolicyCommentResolutionResource", BranchPolicyCommentResolutionArgs.builder()
    .projectId("string")
    .settings(BranchPolicyCommentResolutionSettingsArgs.builder()
        .scopes(BranchPolicyCommentResolutionSettingsScopeArgs.builder()
            .matchType("string")
            .repositoryId("string")
            .repositoryRef("string")
            .build())
        .build())
    .blocking(false)
    .enabled(false)
    .build());
Copy
branch_policy_comment_resolution_resource = azuredevops.BranchPolicyCommentResolution("branchPolicyCommentResolutionResource",
    project_id="string",
    settings={
        "scopes": [{
            "match_type": "string",
            "repository_id": "string",
            "repository_ref": "string",
        }],
    },
    blocking=False,
    enabled=False)
Copy
const branchPolicyCommentResolutionResource = new azuredevops.BranchPolicyCommentResolution("branchPolicyCommentResolutionResource", {
    projectId: "string",
    settings: {
        scopes: [{
            matchType: "string",
            repositoryId: "string",
            repositoryRef: "string",
        }],
    },
    blocking: false,
    enabled: false,
});
Copy
type: azuredevops:BranchPolicyCommentResolution
properties:
    blocking: false
    enabled: false
    projectId: string
    settings:
        scopes:
            - matchType: string
              repositoryId: string
              repositoryRef: string
Copy

BranchPolicyCommentResolution Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The BranchPolicyCommentResolution resource accepts the following input properties:

ProjectId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the project in which the policy will be created.
Settings This property is required. Pulumi.AzureDevOps.Inputs.BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
Blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
Enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
ProjectId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the project in which the policy will be created.
Settings This property is required. BranchPolicyCommentResolutionSettingsArgs
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
Blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
Enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
projectId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the project in which the policy will be created.
settings This property is required. BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking Boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled Boolean
A flag indicating if the policy should be enabled. Defaults to true.
projectId
This property is required.
Changes to this property will trigger replacement.
string
The ID of the project in which the policy will be created.
settings This property is required. BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled boolean
A flag indicating if the policy should be enabled. Defaults to true.
project_id
This property is required.
Changes to this property will trigger replacement.
str
The ID of the project in which the policy will be created.
settings This property is required. BranchPolicyCommentResolutionSettingsArgs
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
projectId
This property is required.
Changes to this property will trigger replacement.
String
The ID of the project in which the policy will be created.
settings This property is required. Property Map
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking Boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled Boolean
A flag indicating if the policy should be enabled. Defaults to true.

Outputs

All input properties are implicitly available as output properties. Additionally, the BranchPolicyCommentResolution resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing BranchPolicyCommentResolution Resource

Get an existing BranchPolicyCommentResolution resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: BranchPolicyCommentResolutionState, opts?: CustomResourceOptions): BranchPolicyCommentResolution
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        blocking: Optional[bool] = None,
        enabled: Optional[bool] = None,
        project_id: Optional[str] = None,
        settings: Optional[BranchPolicyCommentResolutionSettingsArgs] = None) -> BranchPolicyCommentResolution
func GetBranchPolicyCommentResolution(ctx *Context, name string, id IDInput, state *BranchPolicyCommentResolutionState, opts ...ResourceOption) (*BranchPolicyCommentResolution, error)
public static BranchPolicyCommentResolution Get(string name, Input<string> id, BranchPolicyCommentResolutionState? state, CustomResourceOptions? opts = null)
public static BranchPolicyCommentResolution get(String name, Output<String> id, BranchPolicyCommentResolutionState state, CustomResourceOptions options)
resources:  _:    type: azuredevops:BranchPolicyCommentResolution    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
Enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
ProjectId Changes to this property will trigger replacement. string
The ID of the project in which the policy will be created.
Settings Pulumi.AzureDevOps.Inputs.BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
Blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
Enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
ProjectId Changes to this property will trigger replacement. string
The ID of the project in which the policy will be created.
Settings BranchPolicyCommentResolutionSettingsArgs
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking Boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled Boolean
A flag indicating if the policy should be enabled. Defaults to true.
projectId Changes to this property will trigger replacement. String
The ID of the project in which the policy will be created.
settings BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled boolean
A flag indicating if the policy should be enabled. Defaults to true.
projectId Changes to this property will trigger replacement. string
The ID of the project in which the policy will be created.
settings BranchPolicyCommentResolutionSettings
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking bool
A flag indicating if the policy should be blocking. Defaults to true.
enabled bool
A flag indicating if the policy should be enabled. Defaults to true.
project_id Changes to this property will trigger replacement. str
The ID of the project in which the policy will be created.
settings BranchPolicyCommentResolutionSettingsArgs
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.
blocking Boolean
A flag indicating if the policy should be blocking. Defaults to true.
enabled Boolean
A flag indicating if the policy should be enabled. Defaults to true.
projectId Changes to this property will trigger replacement. String
The ID of the project in which the policy will be created.
settings Property Map
A settings block as defined below. Configuration for the policy. This block must be defined exactly once.

Supporting Types

BranchPolicyCommentResolutionSettings
, BranchPolicyCommentResolutionSettingsArgs

Scopes This property is required. List<Pulumi.AzureDevOps.Inputs.BranchPolicyCommentResolutionSettingsScope>
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.
Scopes This property is required. []BranchPolicyCommentResolutionSettingsScope
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.
scopes This property is required. List<BranchPolicyCommentResolutionSettingsScope>
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.
scopes This property is required. BranchPolicyCommentResolutionSettingsScope[]
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.
scopes This property is required. Sequence[BranchPolicyCommentResolutionSettingsScope]
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.
scopes This property is required. List<Property Map>
A scope block as defined below. Controls which repositories and branches the policy will be enabled for. This block must be defined at least once.

BranchPolicyCommentResolutionSettingsScope
, BranchPolicyCommentResolutionSettingsScopeArgs

MatchType string
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
RepositoryId string
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
RepositoryRef string
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.
MatchType string
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
RepositoryId string
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
RepositoryRef string
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.
matchType String
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
repositoryId String
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
repositoryRef String
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.
matchType string
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
repositoryId string
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
repositoryRef string
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.
match_type str
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
repository_id str
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
repository_ref str
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.
matchType String
The match type to use when applying the policy. Supported values are Exact (default), Prefix or DefaultBranch.
repositoryId String
The repository ID. Needed only if the scope of the policy will be limited to a single repository. If match_type is DefaultBranch, this should not be defined.
repositoryRef String
The ref pattern to use for the match when match_type other than DefaultBranch. If match_type is Exact, this should be a qualified ref such as refs/heads/master. If match_type is Prefix, this should be a ref path such as refs/heads/releases.

Import

Azure DevOps Branch Policies can be imported using the project ID and policy configuration ID:

$ pulumi import azuredevops:index/branchPolicyCommentResolution:BranchPolicyCommentResolution example 00000000-0000-0000-0000-000000000000/0
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Azure DevOps pulumi/pulumi-azuredevops
License
Apache-2.0
Notes
This Pulumi package is based on the azuredevops Terraform Provider.