This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Partially incomplete block below - will not work in isolation | |
resource "azuredevops_build_definition" "tf-example-build" { | |
project_id = azuredevops_project.tf-example.id | |
name = "Build Definition for forked-repo" | |
agent_pool_name = "Azure Pipelines" | |
ci_trigger { | |
use_yaml = true | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Partially complete block below - will not work in isolation | |
resource "azuredevops_variable_group" "variablegroup" { | |
project_id = azuredevops_project.tf-example.id | |
name = "Any CPU - Release" | |
description = "This variable group is created using Terraform" | |
allow_access = true | |
variable { | |
name = "buildPlatform" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
provider "azuredevops" { | |
version = ">= 0.0.1" | |
} | |
resource "azuredevops_project" "tf-example" { | |
project_name = "tf-example" | |
description = "Project deployed using Terraform" | |
version_control = "git" | |
visibility = "private" | |
work_item_template = "Agile" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Partially complete blocks below - will not work in isolation | |
resource "azuredevops_group_membership" "tf-group-membership" { | |
group = azuredevops_group.tf-group.descriptor | |
members = [ | |
azuredevops_user_entitlement.tf-user.descriptor | |
] | |
mode = "add" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Partially complete blocks below - will not work in isolation | |
data "azuredevops_group" "group" { | |
project_id = azuredevops_project.tf-example.id | |
name = "Readers" | |
} | |
resource "azuredevops_group_membership" "membership" { | |
group = data.azuredevops_group.group.descriptor | |
members = [ | |
azuredevops_user_entitlement.tf-user.descriptor |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "azuredevops_group" "tf-group" { | |
scope = azuredevops_project.tf-example.id | |
display_name = "Tf test group" | |
description = "This group is created using terraform" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "azuredevops_user_entitlement" "tf-user" { | |
principal_name = "[email protected]" | |
account_license_type = "stakeholder" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data "azuredevops_project" "parent-project" { | |
project_name = "Space Game - web - Pipeline" | |
} | |
data "azuredevops_git_repositories" "parent-repo" { | |
project_id = data.azuredevops_project.parent-project.id | |
name = "Space Game - web" | |
} | |
resource "azuredevops_git_repository" "tf-forked-repo" { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
provider "azuredevops" { | |
version = ">= 0.0.1" | |
} | |
resource "azuredevops_project" "tf-example" { | |
project_name = "tf-example" | |
description = "Project deployed using Terraform" | |
version_control = "git" | |
visibility = "private" | |
work_item_template = "Agile" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "azuredevops_git_repository" "tf-example-repo" { | |
project_id = azuredevops_project.tf-example.id | |
name = "terraform-example-repo" | |
initialization { | |
init_type = "Clean" | |
} | |
} |