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

Add CloudTasksQueue resource #1369

Merged
merged 1 commit into from
Nov 18, 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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions google-beta/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ type Config struct {
CloudFunctionsBasePath string
CloudRunBasePath string
CloudSchedulerBasePath string
CloudTasksBasePath string
ComputeBasePath string
ContainerAnalysisBasePath string
DataFusionBasePath string
Expand Down Expand Up @@ -219,6 +220,7 @@ var CloudBuildDefaultBasePath = "https://cloudbuild.googleapis.com/v1/"
var CloudFunctionsDefaultBasePath = "https://cloudfunctions.googleapis.com/v1/"
var CloudRunDefaultBasePath = "https://run.googleapis.com/v1alpha1/"
var CloudSchedulerDefaultBasePath = "https://cloudscheduler.googleapis.com/v1/"
var CloudTasksDefaultBasePath = "https://cloudtasks.googleapis.com/v2/"
var ComputeDefaultBasePath = "https://www.googleapis.com/compute/beta/"
var ContainerAnalysisDefaultBasePath = "https://containeranalysis.googleapis.com/v1beta1/"
var DataFusionDefaultBasePath = "https://datafusion.googleapis.com/v1beta1/"
Expand Down Expand Up @@ -708,6 +710,7 @@ func ConfigureBasePaths(c *Config) {
c.CloudFunctionsBasePath = CloudFunctionsDefaultBasePath
c.CloudRunBasePath = CloudRunDefaultBasePath
c.CloudSchedulerBasePath = CloudSchedulerDefaultBasePath
c.CloudTasksBasePath = CloudTasksDefaultBasePath
c.ComputeBasePath = ComputeDefaultBasePath
c.ContainerAnalysisBasePath = ContainerAnalysisDefaultBasePath
c.DataFusionBasePath = DataFusionDefaultBasePath
Expand Down
14 changes: 12 additions & 2 deletions google-beta/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,14 @@ func Provider() terraform.ResourceProvider {
"GOOGLE_CLOUD_SCHEDULER_CUSTOM_ENDPOINT",
}, CloudSchedulerDefaultBasePath),
},
"cloud_tasks_custom_endpoint": {
Type: schema.TypeString,
Optional: true,
ValidateFunc: validateCustomEndpoint,
DefaultFunc: schema.MultiEnvDefaultFunc([]string{
"GOOGLE_CLOUD_TASKS_CUSTOM_ENDPOINT",
}, CloudTasksDefaultBasePath),
},
"compute_custom_endpoint": {
Type: schema.TypeString,
Optional: true,
Expand Down Expand Up @@ -482,9 +490,9 @@ func Provider() terraform.ResourceProvider {
return provider
}

// Generated resources: 100
// Generated resources: 101
// Generated IAM resources: 39
// Total generated resources: 139
// Total generated resources: 140
func ResourceMap() map[string]*schema.Resource {
resourceMap, _ := ResourceMapWithErrors()
return resourceMap
Expand Down Expand Up @@ -515,6 +523,7 @@ func ResourceMapWithErrors() (map[string]*schema.Resource, error) {
"google_cloud_run_domain_mapping": resourceCloudRunDomainMapping(),
"google_cloud_run_service": resourceCloudRunService(),
"google_cloud_scheduler_job": resourceCloudSchedulerJob(),
"google_cloud_tasks_queue": resourceCloudTasksQueue(),
"google_compute_address": resourceComputeAddress(),
"google_compute_autoscaler": resourceComputeAutoscaler(),
"google_compute_backend_bucket": resourceComputeBackendBucket(),
Expand Down Expand Up @@ -804,6 +813,7 @@ func providerConfigure(d *schema.ResourceData, terraformVersion string) (interfa
config.CloudFunctionsBasePath = d.Get("cloud_functions_custom_endpoint").(string)
config.CloudRunBasePath = d.Get("cloud_run_custom_endpoint").(string)
config.CloudSchedulerBasePath = d.Get("cloud_scheduler_custom_endpoint").(string)
config.CloudTasksBasePath = d.Get("cloud_tasks_custom_endpoint").(string)
config.ComputeBasePath = d.Get("compute_custom_endpoint").(string)
config.ContainerAnalysisBasePath = d.Get("container_analysis_custom_endpoint").(string)
config.DataFusionBasePath = d.Get("data_fusion_custom_endpoint").(string)
Expand Down
Loading