Wednesday, March 2, 2022

Create NSX-T TAG and Security Group match on this TAG with Terraform

 How to create NSX-T TAG and Security Group match on this TAG with Terraform?


resource "nsxt_policy_vm_tags" "VM123TAG" {

  instance_id = var.vmBIOS

# you can get the vmBIOS from the NSX-T GUI , go to inventory and then Virtual machines

  tag {

    scope = "FWP"

    tag   = "FWP-VPC-1000e-on-P15172"

  }

}



resource "nsxt_policy_group" "SG-FWP-VPC-1000e-on-P15172"{

  display_name = "SG-FWP-VPC-1000e-on-P15172"

  criteria {

    condition {

      key         = "Tag"

      member_type = "VirtualMachine"

      operator    = "EQUALS"

      value       = "FWP|FWP-VPC-1000e-on-P15172"

    }

  }

}

No comments:

Post a Comment

NSX-T (local log in) with VIDM integration

We will explain how to log in with a local account to your NSX-T which integrated with VIDM. We integrated our NSX-T into the VIDM. We had a...