hashicorp / terraform-provider-azuread

Terraform provider for Azure Active Directory
https://registry.terraform.io/providers/hashicorp/azuread/latest/docs
Mozilla Public License 2.0
431 stars 298 forks source link

`access_package_assignment_policy` doesn't support `duration_in_hours` #1148

Open tjrobinson opened 1 year ago

tjrobinson commented 1 year ago

Community Note

Description

The access_package_assignment_policy resource doesn't support duration_in_hours, only duration_in_days (how many days this assignment is valid for).

It is supported through the Azure/Entra portal though:

image

This is unfortunately a limitation in the Graph API itself, see References below, so I don't believe it's possible to implement this feature yet but wanted to raise it so others are aware and to get it onto the backlog.

Please upvote this Microsoft Feedback request to get it added to the Graph API.

New or Affected Resource(s)

Potential Terraform Configuration

resource "azuread_access_package_assignment_policy" "test" {
  access_package_id = azuread_access_package.test.id
  display_name      = "assignment-policy"
  description       = "My assignment policy"
  duration_in_hours = 12

  ...
}

References

tjrobinson commented 7 months ago

Related comment: https://github.com/hashicorp/terraform-provider-azuread/pull/903#issuecomment-1468434056