terraform-provider-azuredevops icon indicating copy to clipboard operation
terraform-provider-azuredevops copied to clipboard

Add support for approvals and other checks (service connections, environments)

Open kensykora opened this issue 3 years ago • 4 comments

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

Please add support for approvals and checks on service connections. This would be helpful so we can audit and automate our security and release policies

image image

This would also be applicable to ADO environments, Service Connections, etc.

New or Affected Resource(s)

  • azuredevops_approval
  • azuredevops_check_business_hours

Potential Terraform Configuration

resource "azuredevops_approval" "prod_approvers" {
  # service_connection_id or environment_id
  service_connection_id = 12345
  users = [
    azuredevops_user.break_glass.id,
    azuredevops_group.production_approvers.id
  ]
  timeout_days = 30
  allow_approve_own = false
  instructions_to_approvers = "Please approve this"
}

resource "azuredevops_check_business_hours" "business_hours" {
  # service_connection_id or environment_id
  environment_id = 3
  monday = false
  tuesday = true
  time_zone_offset = "+00:00"
  start_time = "04:00"
  end_time = "22:00"
}

See other types as well in screen shot above

kensykora avatar Sep 24 '21 17:09 kensykora

@kensykora This resources is supported since v6.1. Blocked by go-sdk https://github.com/microsoft/azure-devops-go-api/issues/93

xuzhang3 avatar Sep 26 '21 03:09 xuzhang3

@xuzhang3 Apparently pipelineschecks is already available on azure-devops-go-api since microsoft/azuredevops-go-api#87. This would indeed be very helpful.

rdalbuquerque avatar Sep 26 '21 23:09 rdalbuquerque

@xuzhang3 Is this still blocked? It looks like the new API version has been released and supports this now

samtarplee avatar Jan 12 '22 10:01 samtarplee

@samtarplee The approvals APIs are available in v6.1, the latest supported API by SDK is v6.0

xuzhang3 avatar Jan 13 '22 03:01 xuzhang3