Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to Terraform Plugin SDK #210

Merged
merged 1 commit into from
Jan 24, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
65 changes: 62 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,68 @@
## 1.1.3 (Unreleased)
## 2.0.0 (Unreleased)

NOTES:

* The provider is extended to support NSX-T policy API. Policy API is intended to be primary consumtion for NSX-T logical constructs, thus users are encouraged to use new data sources/resources, with _policy_ in the name.

FEATURES:
* **New Data Source**: `nsxt_policy_certificate`
* **New Data Source**: `nsxt_policy_edge_cluster`
* **New Data Source**: `nsxt_policy_edge_node`
* **New Data Source**: `nsxt_policy_tier0_gateway`
* **New Data Source**: `nsxt_policy_tier1_gateway`
* **New Data Source**: `nsxt_policy_segment`
* **New Data Source**: `nsxt_policy_vlan_segment`
* **New Data Source**: `nsxt_policy_service`
* **New Data Source**: `nsxt_policy_ip_discovery_profile`
* **New Data Source**: `nsxt_policy_spoofguard_profile`
* **New Data Source**: `nsxt_policy_qos_profile`
* **New Data Source**: `nsxt_policy_segment_security_profile`
* **New Data Source**: `nsxt_policy_mac_discovery_profile`
* **New Data Source**: `nsxt_policy_ipv6_ndra_profile`
* **New Data Source**: `nsxt_policy_ipv6_dad_profile`
* **New Data Source**: `nsxt_policy_vm`
* **New Data Source**: `nsxt_policy_lb_app_profile`
* **New Data Source**: `nsxt_policy_lb_client_ssl_profile`
* **New Data Source**: `nsxt_policy_lb_server_ssl_profile`
* **New Data Source**: `nsxt_policy_lb_monitor`
* **New Data Source**: `nsxt_policy_lb_persistence_profile`
* **New Data Source**: `nsxt_policy_vni_pool`
* **New Data Source**: `nsxt_policy_realization_info`

* **New Resource**: `nsxt_policy_tier0_gateway`
* **New Resource**: `nsxt_policy_tier1_gateway`
* **New Resource**: `nsxt_policy_tier0_gateway_interface`
* **New Resource**: `nsxt_policy_tier1_gateway_interface`
* **New Resource**: `nsxt_policy_group`
* **New Resource**: `nsxt_policy_service`
* **New Resource**: `nsxt_policy_security_policy`
* **New Resource**: `nsxt_policy_gateway_policy`
* **New Resource**: `nsxt_policy_segment`
* **New Resource**: `nsxt_policy_vlan_segment`
* **New Resource**: `nsxt_policy_static_route`
* **New Resource**: `nsxt_policy_nat_rule`
* **New Resource**: `nsxt_policy_vm_tags`
* **New Resource**: `nsxt_policy_ip_block`
* **New Resource**: `nsxt_policy_ip_pool`
* **New Resource**: `nsxt_policy_ip_pool_block_subnet`
* **New Resource**: `nsxt_policy_ip_pool_static_subnet`
* **New Resource**: `nsxt_policy_ip_address_allocation`
* **New Resource**: `nsxt_policy_lb_pool`
* **New Resource**: `nsxt_policy_lb_service`
* **New Resource**: `nsxt_policy_lb_virtual_server`
* **New Resource**: `nsxt_policy_bgp_neighbor`
* **New Resource**: `nsxt_policy_dhcp_relay`
* **New Resource**: `nsxt_policy_dhcp_server`

BUG FIXES:
* Fix client authentication error that used to occur when client certificate is not self signed ([#207](https://github.com/terraform-providers/terraform-provider-nsxt/pull/207))
* Allow IPv6 in IP addresses and CIDR validations ([#204](https://github.com/terraform-providers/terraform-provider-nsxt/pull/204))

## 1.1.2 (November 18, 2019)

FEATURES:
* **New Data Source**: `nsxt_ip_pool` ([#109](https://github.com/terraform-providers/terraform-provider-nsxt/pull/190))
* **New Resource**: `nsxt_ip_pool_allocation_ip_address` ([#109](https://github.com/terraform-providers/terraform-provider-nsxt/pull/190))
* **New Data Source**: `nsxt_ip_pool` ([#190](https://github.com/terraform-providers/terraform-provider-nsxt/pull/190))
* **New Resource**: `nsxt_ip_pool_allocation_ip_address` ([#190](https://github.com/terraform-providers/terraform-provider-nsxt/pull/190))

IMPROVEMENTS:
* `resource/nsxt_ns_group`: Support IPSet type in membership criteria ([#195](https://github.com/terraform-providers/terraform-provider-nsxt/pull/195))
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ module github.com/terraform-providers/terraform-provider-nsxt

require (
github.com/google/uuid v1.1.1
github.com/hashicorp/go-version v1.1.0
github.com/hashicorp/terraform v0.12.0
github.com/hashicorp/go-version v1.2.0
github.com/hashicorp/terraform-plugin-sdk v1.1.0
github.com/vmware/go-vmware-nsxt v0.0.0-20191219213550-f4221331f638
github.com/vmware/vsphere-automation-sdk-go/lib v0.1.1
github.com/vmware/vsphere-automation-sdk-go/runtime v0.1.1
Expand Down
372 changes: 135 additions & 237 deletions go.sum

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
package main

import (
"github.com/hashicorp/terraform/plugin"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/plugin"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/terraform-providers/terraform-provider-nsxt/nsxt"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_certificate.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/trust"
"net/http"
)
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_edge_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_edge_cluster_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_ip_pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
)
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_ip_pool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_logical_tier0_router.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_logical_tier0_router_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_logical_tier1_router.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"strings"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_logical_tier1_router_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"testing"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_mac_pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
)
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_mac_pool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_ns_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
)
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_ns_group_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"testing"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_ns_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
)
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_ns_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/go-vmware-nsxt/manager"
"net/http"
"testing"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_certificate.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_certificate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_edge_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra/sites/enforcement_points"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_edge_cluster_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_edge_node.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/helper/validation"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/validation"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra/sites/enforcement_points/edge_clusters"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_edge_node_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"testing"
)

Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_ip_discovery_profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_ip_discovery_profile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"testing"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_ipv6_dad_profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_ipv6_dad_profile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"testing"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_ipv6_ndra_profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_ipv6_ndra_profile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"testing"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_lb_app_profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/helper/validation"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/validation"
"github.com/vmware/vsphere-automation-sdk-go/runtime/bindings"
"github.com/vmware/vsphere-automation-sdk-go/runtime/data"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_lb_app_profile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/vsphere-automation-sdk-go/runtime/bindings"
"github.com/vmware/vsphere-automation-sdk-go/runtime/data"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
Expand Down
2 changes: 1 addition & 1 deletion nsxt/data_source_nsxt_policy_lb_client_ssl_profile.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"strings"
Expand Down
4 changes: 2 additions & 2 deletions nsxt/data_source_nsxt_policy_lb_client_ssl_profile_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ package nsxt

import (
"fmt"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/infra"
"github.com/vmware/vsphere-automation-sdk-go/services/nsxt/model"
"testing"
Expand Down
Loading