Skip to content

Commit

Permalink
Add doc for Transport Zone
Browse files Browse the repository at this point in the history
Signed-off-by: Shawn Wang <[email protected]>
  • Loading branch information
wsquan171 committed Aug 17, 2023
1 parent 13ed5c6 commit c0d85ff
Show file tree
Hide file tree
Showing 3 changed files with 70 additions and 3 deletions.
4 changes: 2 additions & 2 deletions website/docs/d/policy_transport_zone.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ data "nsxt_policy_transport_zone" "overlay_transport_zone" {

* `id` - (Optional) The ID of Transport Zone to retrieve.
* `display_name` - (Optional) The Display Name prefix of the Transport Zone to retrieve.
* `transport_type` - (Optional) Transport type of requested Transport Zone, one of `OVERLAY_STANDARD`, `OVERLAY_ENS`, `VLAN_BACKED` and `UNKNOWN`.
* `is_default` - (Optional) May be set together with `transport_type` in order to retrieve default Transport Zone for for this transport type.
* `transport_type` - (Optional) Transport type of requested Transport Zone, one of `OVERLAY_STANDARD`, `OVERLAY_ENS`, `OVERLAY_BACKED`, `VLAN_BACKED` and `UNKNOWN`.
* `is_default` - (Optional) May be set together with `transport_type` in order to retrieve default Transport Zone for this transport type.
* `site_path` - (Optional) The path of the site which the Transport Zone belongs to, this configuration is required for global manager only. `path` field of the existing `nsxt_policy_site` can be used here.

## Attributes Reference
Expand Down
67 changes: 67 additions & 0 deletions website/docs/r/policy_transport_zone.html.markdown
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
subcategory: "Fabric"
layout: "nsxt"
page_title: "NSXT: nsxt_policy_transport_zone"
description: A resource to configure Policy Transport Zone.
---

# nsxt_policy_transport_zone

This resource provides a method for the management of Policy based Transport Zones (TZ). A Transport Zone defines the scope to which a network can extend in NSX. For example an overlay based Transport Zone is associated with both hypervisors and logical switches and defines which hypervisors will be able to serve the defined logical switch. Virtual machines on the hypervisor associated with a Transport Zone can be attached to logical switches in that same Transport Zone.

This data source is applicable to NSX Policy Manager.

## Example Usage

```hcl
resource "nsxt_policy_transport_zone" "overlay_transport_zone" {
display_name = "1-transportzone-87"
transport_type = "OVERLAY_BACKED"
}
```

```hcl
resource "nsxt_policy_transport_zone" "vlan_transport_zone" {
display_name = "1-transportzone-87"
description = "VLAN transport zone"
transport_type = "VLAN_BACKED"
is_default = true
uplink_teaming_policy_names = ["teaming-1"]
site_path = "/infra/sites/default"
enforcement_point_id = "default"
tag {
scope = "app"
tag = "web"
}
}
```

## Argument Reference

* `display_name` - (Optional) The Display Name of the Transport Zone.
* `description` - (Optional) Description of the Transport Zone.
* `tag` - (Optional) A list of scope + tag pairs to associate with this resource.
* `nsx_id` - (Optional) The NSX ID of this resource. If set, this ID will be used to create the policy resource.
* `transport_type` - (Required) Transport type of requested Transport Zone, one of `OVERLAY_STANDARD`, `OVERLAY_ENS`, `OVERLAY_BACKED`, `VLAN_BACKED` and `UNKNOWN`.
* `is_default` - (Optional) Set this Transport Zone as the default zone of given `transport_type`. Default value is `false`. When setting a Transport Zone with `is_default`: `true`, no existing Transport Zone of same `transport_type` should be set as default.
* `uplink_teaming_policy_names` - (Optional) The names of switching uplink teaming policies that all transport nodes in this transport zone support. Uplinkin teaming policies are only valid for `VLAN_BACKED` transport zones.
* `site_path` - (Optional) The path of the site which the Transport Zone belongs to. `path` field of the existing `nsxt_policy_site` can be used here.
* `enforcement_point_id` - (Optional) The ID of enforcement point under given `site_path` to manage the Transport Zone.

## Attributes Reference

In addition to arguments listed above, the following attributes are exported:

* `revision` - Indicates current revision number of the object as seen by NSX-T API server. This attribute can be useful for debugging.
* `path` - The NSX path of the policy resource.

## Importing

An existing Transport Zone can be [imported][docs-import] into this resource, via the following command:

[docs-import]: https://www.terraform.io/cli/import
```
terraform import nsxt_policy_transport_zone.overlay-tz POLICY_PATH
```
The above command imports the Transport Zone named `overlay-tz` with the policy path `POLICY_PATH`.
2 changes: 1 addition & 1 deletion website/docs/r/policy_vni_pool.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,4 @@ The above command imports the VNI Pool named `vnipool1` with the NSX Policy ID `
terraform import nsxt_policy_vni_pool.vnipool1 POLICY_PATH
```
The above command imports the VNI pool named `vnipool1` with the policy path `POLICY_PATH`.
Note: for multitenancy projects only the later form is usable.
Note: for multitenancy projects only the later form is usable.

0 comments on commit c0d85ff

Please sign in to comment.