0
votes

I have VS2019 and trying to create Logic Apps which includes SQL connection. I deploy this LogicApps with Azure DevOps and getting error. I do not what is purpose of sql_1_privacySetting and what are possible values I could use. Specially I'm wondering how to set values in ARM.

ERROR:

##[error]Deployment template validation failed: 'The provided value 'Microsoft.WindowsAzure.ResourceStack.Frontdoor.Common.Entities.TemplateGenericProperty`1[Newtonsoft.Json.Linq.JToken]' for the template parameter 'sql_1_privacySetting' at line '1' and column '1605' is not valid. The parameter value is not part of the allowed value(s): 'None,Private,Organizational,Public'.'.

LogicApp.parameters.json

"sql_1_encryptConnection": {
  "value": false
},
"sql_1_privacySetting": {
  "value": ""
},

LogicApp.json

{
  "type": "MICROSOFT.WEB/CONNECTIONS",
  "apiVersion": "2018-07-01-preview",
  "name": "[parameters('sql_1_Connection_Name')]",
  "location": "[parameters('logicAppLocation')]",
  "properties": {
    "api": {
      "id": "[concat(subscription().id, '/providers/Microsoft.Web/locations/', parameters('logicAppLocation'), '/managedApis/', 'sql')]"
    },
    "displayName": "[parameters('sql_1_Connection_DisplayName')]",
    "parameterValues": {
      "server": "[parameters('sql_1_server')]",
      "database": "[parameters('sql_1_database')]",
      "username": "[parameters('sql_1_username')]",
      "password": "[parameters('sql_1_password')]",
      "encryptConnection": "[parameters('sql_1_encryptConnection')]",
      "privacySetting": "[parameters('sql_1_privacySetting')]",
      "sqlConnectionString": "[parameters('sql_1_sqlConnectionString')]"
    }
  }
}
1
This article describes how to resolve invalid template errors:Double check the allowed values in the template, and provide one during deployment.Hugh Lin

1 Answers

0
votes

In my LogicApp.json it has these as the possible privacySetting allowed values:

"sql_1_privacySetting": {
  "type": "string",
  "metadata": {
    "description": "Privacy Setting"
  },
  "allowedValues": [
    "None",
    "Private",
    "Organizational",
    "Public"
  ]
},