From cab7e789f3b1cbdeff1b4e75e4f2f31aa10c3aab Mon Sep 17 00:00:00 2001 From: Tom Harvey Date: Fri, 21 Dec 2018 12:46:39 +0100 Subject: [PATCH] Enforce read & write permissions values Co-Authored-By: pdecat --- azurerm/resource_arm_application_insights_api_key.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/azurerm/resource_arm_application_insights_api_key.go b/azurerm/resource_arm_application_insights_api_key.go index 3cb63d726340a..d262728da8ce6 100644 --- a/azurerm/resource_arm_application_insights_api_key.go +++ b/azurerm/resource_arm_application_insights_api_key.go @@ -6,10 +6,10 @@ import ( "github.com/terraform-providers/terraform-provider-azurerm/azurerm/helpers/azure" "github.com/terraform-providers/terraform-provider-azurerm/azurerm/helpers/tf" - "github.com/terraform-providers/terraform-provider-azurerm/azurerm/helpers/validate" "github.com/Azure/azure-sdk-for-go/services/appinsights/mgmt/2015-05-01/insights" "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform/helper/validation" "github.com/terraform-providers/terraform-provider-azurerm/azurerm/utils" ) @@ -48,7 +48,7 @@ func resourceArmApplicationInsightsAPIKey() *schema.Resource { Set: schema.HashString, Elem: &schema.Schema{ Type: schema.TypeString, - ValidateFunc: validate.LowercaseString, + ValidateFunc: validation.StringInSlice([]string{"agentconfig", "aggregate", "api", "draft", "extendqueries", "search"}, false), }, }, @@ -59,7 +59,7 @@ func resourceArmApplicationInsightsAPIKey() *schema.Resource { Set: schema.HashString, Elem: &schema.Schema{ Type: schema.TypeString, - ValidateFunc: validate.LowercaseString, + ValidateFunc: validation.StringInSlice([]string{"annotations"}, false), }, }, },