title: Azure - can't find serverfarm
body: <p>I am trying to deploy my ARM template and t failing on serverfarms creation step. I took example from Microsoft site <a href="https://docs.microsoft.com/en-us/azure/templates/microsoft.web/serverfarms" rel="nofollow noreferrer">Microsoft docks</a>. I can't understand why it happens</p>
  
  <p>Here is an error code, I change location fro North to West Europe,I try with variable incited of parameter. Nothing helps.</p>
  
  <pre><code>    Resource Microsoft.Web/serverfarms 'ASE-APP-SERVICE-PLAN' failed with message '{
    "Code": "NotFound",
    "Message": "Server farm with name ASE-APP-SERVICE-PLAN not found.",
    "Target": null,
    "Details": [
      {
        "Message": "Server farm with name ASE-APP-SERVICE-PLAN not found."
      },
      {
        "Code": "NotFound"
      },
      {
        "ErrorEntity": {
          "ExtendedCode": "11001",
          "MessageTemplate": "Server farm with name {0} not found.",
          "Parameters": [
            "ASE-APP-SERVICE-PLAN"
          ],
          "Code": "NotFound",
          "Message": "Server farm with name ASE-APP-SERVICE-PLAN not found."
        }
      }
    ],
    "Innererror": null
  }'
  </code></pre>
  
  <p>Here is my simple arm template</p>
  
  <pre><code>{
  "$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json",
  "contentVersion": "1.0.0.0",
  "parameters": {
      "aseName": {
          "type": "string",
          "defaultValue": "ASE-TEST",
          "metadata": {
              "description": "Name of the App Service Environment"
          }
      },
      "aseLocation": {
          "type": "string",
          "defaultValue": "West Europe",
          "metadata": {
              "description": "Location of the App Service Environment"
          }
      },
      "APP-SPLANName": {
          "type": "string",
          "defaultValue": "ASE-APP-SERVICE-PLAN",
          "metadata": {
              "description": "App service plan name"
          }
      }
  },
  "variables": {
    "ASE-VNetPrefix": "10.0.0.0/16",
    "ASE-VNetSubnet1Name": "Subnet-1",
    "ASE-VNetSubnet1Prefix": "10.0.0.0/24",
    "ASE-VNET-Name": "[concat('ASE-VNET', uniqueString(resourceGroup().id))]",
    "WEB-APP-ASEv2Name": "[concat('WEB-APP-ASEv2', uniqueString(resourceGroup().id))]"
  
  },
  "resources": [
      {
          "name": "[variables('ASE-VNET-Name')]",
          "type": "Microsoft.Network/virtualNetworks",
          "location": "[resourceGroup().location]",
          "apiVersion": "2016-03-30",
          "dependsOn": [],
          "tags": {
              "displayName": "ASE-VNET"
          },
          "properties": {
              "addressSpace": {
                  "addressPrefixes": [
                      "[variables('ASE-VNetPrefix')]"
                  ]
              },
              "subnets": [
                  {
                      "name": "[variables('ASE-VNetSubnet1Name')]",
                      "properties": {
                          "addressPrefix": "[variables('ASE-VNetSubnet1Prefix')]"
                      }
                  }
              ]
          }
      },
      {
          "apiVersion": "2015-08-01",
          "type": "Microsoft.Web/hostingEnvironments",
          "name": "[parameters('aseName')]",
          "kind": "ASEV2",
          "location": "[parameters('aseLocation')]",
          "dependsOn": [
              "[resourceId('Microsoft.Network/virtualNetworks', variables('ASE-VNET-Name'))]"
          ],
          "properties": {
              "name": "[parameters('aseName')]",
              "location": "[parameters('aseLocation')]",
              "virtualNetwork": {
                  "Id": "[concat('/subscriptions/',subscription().subscriptionId,'/resourceGroups/',resourceGroup().name,'/providers/Microsoft.Network/virtualNetworks/', variables('ASE-VNET-Name'))]",
                  "Subnet": "[variables('ASE-VNETSubnet1Name')]"
              }
          }
      },
      {
          "name": "[parameters('APP-SPLANName')]",
          "type": "Microsoft.Web/serverfarms",
          "location": "[parameters('aseLocation')]",
          "apiVersion": "2016-09-01",
          "tags": {},
          "properties": {
              "name": "[parameters('APP-SPLANName')]",
              "hostingEnvironmentProfile": {
                  "id": "[resourceId('Microsoft.Web/hostingEnvironments', parameters('aseName'))]"
              }
          },
          "sku": {
              "name": "I1",
              "tier": "Isolated",
              "size": "I1",
              "family": "I",
              "capacity": 0
          },
          "dependsOn": [
              "[resourceId('Microsoft.Web/hostingEnvironments', parameters('aseName'))]"
          ]
      },
    {
      "name": "[variables('WEB-APP-ASEv2Name')]",
      "type": "Microsoft.Web/sites",
      "location": "[resourceGroup().location]",
      "apiVersion": "2016-08-01",
      "tags": {},
      "properties": {
          "name": "[variables('WEB-APP-ASEv2Name')]",
          "hostingEnvironmentProfile": {
              "id": "[resourceId('Microsoft.Web/hostingEnvironments', parameters('aseName'))]"
          },
          "serverFarmId": "[resourceId('Microsoft.Web/serverfarms', parameters('APP-SPLANName'))]"
      },
      "dependsOn": [
          "[resourceId('Microsoft.Web/serverfarms', parameters('APP-SPLANName'))]",
          "[resourceId('Microsoft.Web/hostingEnvironments', parameters('aseName'))]"
      ]
    }
  ]
  </code></pre>
  
  <p>}</p>