Skip to content

Commit

Permalink
Output from magician generating into ga and beta providers
Browse files Browse the repository at this point in the history
  • Loading branch information
danawillow authored and modular-magician committed Oct 19, 2018
1 parent 017fcb6 commit e408ab4
Show file tree
Hide file tree
Showing 57 changed files with 631 additions and 415 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ func dataSourceGoogleContainerEngineVersions() *schema.Resource {
Optional: true,
},
"region": {
Deprecated: "This field is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeString,
Optional: true,
ConflictsWith: []string{"zone"},
Expand Down
25 changes: 11 additions & 14 deletions google-beta/iam_compute_subnetwork.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,23 @@ import (

var IamComputeSubnetworkSchema = map[string]*schema.Schema{
"subnetwork": {
Deprecated: "This resource is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeString,
Required: true,
ForceNew: true,
Type: schema.TypeString,
Required: true,
ForceNew: true,
},

"project": {
Deprecated: "This resource is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
Type: schema.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
},

"region": {
Deprecated: "This resource is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
Type: schema.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
},
}

Expand Down
10 changes: 4 additions & 6 deletions google-beta/node_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,6 @@ var schemaNodeConfig = &schema.Schema{
},

"taint": {
Deprecated: "This field is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeList,
Optional: true,
ForceNew: true,
Expand Down Expand Up @@ -170,11 +169,10 @@ var schemaNodeConfig = &schema.Schema{
},

"workload_metadata_config": {
Deprecated: "This field is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeList,
Optional: true,
ForceNew: true,
MaxItems: 1,
Type: schema.TypeList,
Optional: true,
ForceNew: true,
MaxItems: 1,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"node_metadata": {
Expand Down
3 changes: 0 additions & 3 deletions google-beta/resource_binaryauthorization_attestor.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@ func resourceBinaryAuthorizationAttestor() *schema.Resource {
Importer: &schema.ResourceImporter{
State: resourceBinaryAuthorizationAttestorImport,
},
DeprecationMessage: `This resource is in beta and will be removed from this provider.
Use the BinaryAuthorizationAttestor resource in the terraform-provider-google-beta provider to continue using it.
See https://terraform.io/docs/providers/google/provider_versions.html for more details on beta resources.`,

Schema: map[string]*schema.Schema{
"attestation_authority_note": {
Expand Down
3 changes: 0 additions & 3 deletions google-beta/resource_binaryauthorization_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,6 @@ func resourceBinaryAuthorizationPolicy() *schema.Resource {
Importer: &schema.ResourceImporter{
State: resourceBinaryAuthorizationPolicyImport,
},
DeprecationMessage: `This resource is in beta and will be removed from this provider.
Use the BinaryAuthorizationPolicy resource in the terraform-provider-google-beta provider to continue using it.
See https://terraform.io/docs/providers/google/provider_versions.html for more details on beta resources.`,

Schema: map[string]*schema.Schema{
"default_admission_rule": {
Expand Down
8 changes: 4 additions & 4 deletions google-beta/resource_compute_autoscaler.go
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ func resourceComputeAutoscalerCreate(d *schema.ResourceData, meta interface{}) e
obj["zone"] = zoneProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/autoscalers")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/autoscalers")
if err != nil {
return err
}
Expand Down Expand Up @@ -235,7 +235,7 @@ func resourceComputeAutoscalerCreate(d *schema.ResourceData, meta interface{}) e
func resourceComputeAutoscalerRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/autoscalers/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/autoscalers/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -312,7 +312,7 @@ func resourceComputeAutoscalerUpdate(d *schema.ResourceData, meta interface{}) e
obj["zone"] = zoneProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/autoscalers?autoscaler={{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/autoscalers?autoscaler={{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -348,7 +348,7 @@ func resourceComputeAutoscalerUpdate(d *schema.ResourceData, meta interface{}) e
func resourceComputeAutoscalerDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/autoscalers/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/autoscalers/{{name}}")
if err != nil {
return err
}
Expand Down
8 changes: 4 additions & 4 deletions google-beta/resource_compute_backend_bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ func resourceComputeBackendBucketCreate(d *schema.ResourceData, meta interface{}
obj["name"] = nameProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/backendBuckets")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/backendBuckets")
if err != nil {
return err
}
Expand Down Expand Up @@ -153,7 +153,7 @@ func resourceComputeBackendBucketCreate(d *schema.ResourceData, meta interface{}
func resourceComputeBackendBucketRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/backendBuckets/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/backendBuckets/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -221,7 +221,7 @@ func resourceComputeBackendBucketUpdate(d *schema.ResourceData, meta interface{}
obj["name"] = nameProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/backendBuckets/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/backendBuckets/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -257,7 +257,7 @@ func resourceComputeBackendBucketUpdate(d *schema.ResourceData, meta interface{}
func resourceComputeBackendBucketDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/backendBuckets/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/backendBuckets/{{name}}")
if err != nil {
return err
}
Expand Down
9 changes: 4 additions & 5 deletions google-beta/resource_compute_backend_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,11 +159,10 @@ func resourceComputeBackendService() *schema.Resource {
},

"custom_request_headers": &schema.Schema{
Deprecated: "This field is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeSet,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
Type: schema.TypeSet,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
},

"description": &schema.Schema{
Expand Down
10 changes: 5 additions & 5 deletions google-beta/resource_compute_disk.go
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ func resourceComputeDiskCreate(d *schema.ResourceData, meta interface{}) error {
return err
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/disks")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/disks")
if err != nil {
return err
}
Expand Down Expand Up @@ -542,7 +542,7 @@ func resourceComputeDiskCreate(d *schema.ResourceData, meta interface{}) error {
func resourceComputeDiskRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/disks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/disks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -645,7 +645,7 @@ func resourceComputeDiskUpdate(d *schema.ResourceData, meta interface{}) error {
obj["labels"] = labelsProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/disks/{{name}}/setLabels")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/disks/{{name}}/setLabels")
if err != nil {
return err
}
Expand Down Expand Up @@ -684,7 +684,7 @@ func resourceComputeDiskUpdate(d *schema.ResourceData, meta interface{}) error {
obj["sizeGb"] = sizeGbProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/disks/{{name}}/resize")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/disks/{{name}}/resize")
if err != nil {
return err
}
Expand Down Expand Up @@ -722,7 +722,7 @@ func resourceComputeDiskUpdate(d *schema.ResourceData, meta interface{}) error {
func resourceComputeDiskDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/zones/{{zone}}/disks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/zones/{{zone}}/disks/{{name}}")
if err != nil {
return err
}
Expand Down
9 changes: 4 additions & 5 deletions google-beta/resource_compute_global_forwarding_rule.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,10 @@ func resourceComputeGlobalForwardingRule() *schema.Resource {
},

"labels": &schema.Schema{
Deprecated: "This field is in beta and will be removed from this provider. Use it in the the google-beta provider instead. See https://terraform.io/docs/providers/google/provider_versions.html for more details.",
Type: schema.TypeMap,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
Type: schema.TypeMap,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
},

"label_fingerprint": &schema.Schema{
Expand Down
8 changes: 4 additions & 4 deletions google-beta/resource_compute_health_check.go
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ func resourceComputeHealthCheckCreate(d *schema.ResourceData, meta interface{})
return err
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/healthChecks")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/healthChecks")
if err != nil {
return err
}
Expand Down Expand Up @@ -329,7 +329,7 @@ func resourceComputeHealthCheckCreate(d *schema.ResourceData, meta interface{})
func resourceComputeHealthCheckRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/healthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/healthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -456,7 +456,7 @@ func resourceComputeHealthCheckUpdate(d *schema.ResourceData, meta interface{})

obj, err = resourceComputeHealthCheckEncoder(d, meta, obj)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/healthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/healthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -492,7 +492,7 @@ func resourceComputeHealthCheckUpdate(d *schema.ResourceData, meta interface{})
func resourceComputeHealthCheckDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/healthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/healthChecks/{{name}}")
if err != nil {
return err
}
Expand Down
8 changes: 4 additions & 4 deletions google-beta/resource_compute_http_health_check.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ func resourceComputeHttpHealthCheckCreate(d *schema.ResourceData, meta interface
obj["unhealthyThreshold"] = unhealthyThresholdProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpHealthChecks")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpHealthChecks")
if err != nil {
return err
}
Expand Down Expand Up @@ -209,7 +209,7 @@ func resourceComputeHttpHealthCheckCreate(d *schema.ResourceData, meta interface
func resourceComputeHttpHealthCheckRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -322,7 +322,7 @@ func resourceComputeHttpHealthCheckUpdate(d *schema.ResourceData, meta interface
obj["unhealthyThreshold"] = unhealthyThresholdProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -358,7 +358,7 @@ func resourceComputeHttpHealthCheckUpdate(d *schema.ResourceData, meta interface
func resourceComputeHttpHealthCheckDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down
8 changes: 4 additions & 4 deletions google-beta/resource_compute_https_health_check.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ func resourceComputeHttpsHealthCheckCreate(d *schema.ResourceData, meta interfac
obj["unhealthyThreshold"] = unhealthyThresholdProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpsHealthChecks")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpsHealthChecks")
if err != nil {
return err
}
Expand Down Expand Up @@ -209,7 +209,7 @@ func resourceComputeHttpsHealthCheckCreate(d *schema.ResourceData, meta interfac
func resourceComputeHttpsHealthCheckRead(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpsHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpsHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -322,7 +322,7 @@ func resourceComputeHttpsHealthCheckUpdate(d *schema.ResourceData, meta interfac
obj["unhealthyThreshold"] = unhealthyThresholdProp
}

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpsHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpsHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down Expand Up @@ -358,7 +358,7 @@ func resourceComputeHttpsHealthCheckUpdate(d *schema.ResourceData, meta interfac
func resourceComputeHttpsHealthCheckDelete(d *schema.ResourceData, meta interface{}) error {
config := meta.(*Config)

url, err := replaceVars(d, config, "https://www.googleapis.com/compute/v1/projects/{{project}}/global/httpsHealthChecks/{{name}}")
url, err := replaceVars(d, config, "https://www.googleapis.com/compute/beta/projects/{{project}}/global/httpsHealthChecks/{{name}}")
if err != nil {
return err
}
Expand Down
Loading

0 comments on commit e408ab4

Please sign in to comment.