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

Update Terraform SDK to the new Terraform Plugin SDK library #78

Merged
merged 1 commit into from
Sep 25, 2019
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
  •  
  •  
  •  
7 changes: 3 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@ exclude (

require (
github.com/google/go-cmp v0.3.0
github.com/hashicorp/go-hclog v0.9.1 // indirect
github.com/gorilla/websocket v1.4.1 // indirect
github.com/hashicorp/go-multierror v1.0.0
github.com/hashicorp/go-version v1.1.0
github.com/hashicorp/go-version v1.2.0
github.com/hashicorp/hcl v0.0.0-20170504190234-a4b07c25de5f
github.com/hashicorp/nomad/api v0.0.0-20190906191921-82f214630cd6
github.com/hashicorp/terraform v0.12.8
github.com/hashicorp/terraform-plugin-sdk v1.0.0
github.com/hashicorp/vault v0.10.4
github.com/hashicorp/yamux v0.0.0-20180917205041-7221087c3d28 // indirect
github.com/mitchellh/mapstructure v1.1.2
github.com/stretchr/testify v1.3.0
)
434 changes: 100 additions & 334 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package main

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

Expand Down
2 changes: 1 addition & 1 deletion nomad/data_source_deployments.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strconv"
"strings"

"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func dataSourceDeployments() *schema.Resource {
Expand Down
4 changes: 2 additions & 2 deletions nomad/data_source_deployments_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"strconv"
"testing"

"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"
)

// Test will
Expand Down
2 changes: 1 addition & 1 deletion nomad/data_source_namespaces.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"log"

"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func dataSourceNamespaces() *schema.Resource {
Expand Down
4 changes: 2 additions & 2 deletions nomad/data_source_namespaces_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strconv"
"testing"

"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"
)

func TestDataSourceNamespaces(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion nomad/data_source_regions.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"log"

"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func dataSourceRegions() *schema.Resource {
Expand Down
4 changes: 2 additions & 2 deletions nomad/data_source_regions_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strconv"
"testing"

"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"
)

func TestDataSourceRegions(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion nomad/datasource_nomad_job.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func dataSourceJob() *schema.Resource {
Expand Down
4 changes: 2 additions & 2 deletions nomad/datasource_nomad_job_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (

"github.com/hashicorp/nomad/api"

"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"
)

func TestAccDataSourceNomadJob_Basic(t *testing.T) {
Expand Down
4 changes: 2 additions & 2 deletions nomad/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"fmt"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"github.com/hashicorp/vault/command/config"
)

Expand Down
4 changes: 2 additions & 2 deletions nomad/provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"testing"

"github.com/hashicorp/go-version"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
)

// How to run the acceptance tests for this provider:
Expand Down
2 changes: 1 addition & 1 deletion nomad/resource_acl_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func resourceACLPolicy() *schema.Resource {
Expand Down
6 changes: 3 additions & 3 deletions nomad/resource_acl_policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ import (
"strings"
"testing"

"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
)

func TestResourceACLPolicy_import(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion nomad/resource_acl_token.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func resourceACLToken() *schema.Resource {
Expand Down
4 changes: 2 additions & 2 deletions nomad/resource_acl_token_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"strings"
"testing"

"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"
)

func TestResourceACLToken_import(t *testing.T) {
Expand Down
4 changes: 2 additions & 2 deletions nomad/resource_job.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import (
"time"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/terraform-providers/terraform-provider-nomad/nomad/core/jobspec"
)

Expand Down
8 changes: 4 additions & 4 deletions nomad/resource_job_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ import (

"github.com/hashicorp/nomad/api"

"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"

r "github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
r "github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
)

func TestResourceJob_basic(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion nomad/resource_namespace.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"time"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func resourceNamespace() *schema.Resource {
Expand Down
6 changes: 3 additions & 3 deletions nomad/resource_namespace_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"testing"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
)

func TestResourceNamespace_import(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion nomad/resource_quota_specification.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"strings"

"github.com/hashicorp/nomad/api"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)

func resourceQuotaSpecification() *schema.Resource {
Expand Down
6 changes: 3 additions & 3 deletions nomad/resource_quota_specification_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"strings"
"testing"

"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"

"github.com/hashicorp/nomad/api"
)
Expand Down
4 changes: 2 additions & 2 deletions nomad/resource_sentinel_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"strings"

"github.com/hashicorp/nomad/api"
"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"
)

func resourceSentinelPolicy() *schema.Resource {
Expand Down
6 changes: 3 additions & 3 deletions nomad/resource_sentinel_policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ import (
"strings"
"testing"

"github.com/hashicorp/terraform/helper/acctest"
"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/terraform"
"github.com/hashicorp/terraform-plugin-sdk/helper/acctest"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
)

func TestResourceSentinelPolicy_import(t *testing.T) {
Expand Down
15 changes: 0 additions & 15 deletions vendor/cloud.google.com/go/AUTHORS

This file was deleted.

40 changes: 0 additions & 40 deletions vendor/cloud.google.com/go/CONTRIBUTORS

This file was deleted.

13 changes: 13 additions & 0 deletions vendor/cloud.google.com/go/compute/metadata/metadata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading