cisco-en-programmability / terraform-provider-dnacenter

https://registry.terraform.io/providers/cisco-en-programmability/dnacenter/latest/docs
MIT License
14 stars 12 forks source link

Cannot create a new area using dnacenter_site #156

Closed asummerau closed 1 year ago

asummerau commented 1 year ago

Prerequisites

Describe the bug When upgrading the Terraform provider to 1.1.0-beta it is no longer possible to create a new (non-existing) area using the resource dnacenter_site, as given below. Prior to 1.1.0-beta, it was possible to create a new area by using exactly this code.

resource "dnacenter_site" "subarea" {
  provider = dnacenter
  parameters {
    site {
      area {
        name = var.subarea_name
        parent_name = "${var.area_parent_name}/${var.area_name}"
      }
    }
  type = "area"
  }
}

With 1.1.0-beta, the error message appears telling that the "site_id" is missing. However, to create a new area, the id is not yet known and cannot be specified at this step. Screenshot 2023-04-19 at 17 13 38

Expected behavior As in prior versions, this resource should create a new area when no "site_id" is specified.

Screenshots

Screenshot 2023-04-19 at 16 59 12

Environment (please complete the following information):

Additional context

fmunozmiranda commented 1 year ago

Hi @asummerau please try it again with v1.1.1-beta and let us know if it works for you.