0

I'm trying to deploy a resource group. I first set one up through the portal, and now am trying to modify the exported arm templates to be able to setup a second environment. I can get the app-service-plan, and the app-service to create however if has the wrong runtime. When I try to add in the part from the exported template that changes it however I get an error saying the parameter LinuxFxVersion has an invalid value. Here is the related part of the arm template for changing the config:

{
    "type": "Microsoft.Web/sites/config",
    "apiVersion": "2018-11-01",
    "name": "[concat(parameters('app_service_name'), '/web')]",
    "location": "North Central US",
    "dependsOn": [
        "[resourceId('Microsoft.Web/sites', parameters('app_service_name'))]"
    ],
    "properties": {
        "numberOfWorkers": 1,
        "defaultDocuments": [
            "Default.htm",
            "Default.html",
            "Default.asp",
            "index.htm",
            "index.html",
            "iisstart.htm",
            "default.aspx",
            "index.php",
            "hostingstart.html"
        ],
        "netFrameworkVersion": "v4.0",
        "linuxFxVersion": "DOTNETCORE|3.0",
        "requestTracingEnabled": false,
        "remoteDebuggingEnabled": false,
        "remoteDebuggingVersion": "VS2019",
        "httpLoggingEnabled": false,
        "logsDirectorySizeLimit": 35,
        "detailedErrorLoggingEnabled": false,
        "publishingUsername": "$someusername",
        "scmType": "BitbucketGit",
        "use32BitWorkerProcess": true,
        "webSocketsEnabled": false,
        "alwaysOn": false,
        "managedPipelineMode": "Integrated",
        "virtualApplications": [
            {
                "virtualPath": "/",
                "physicalPath": "site\\wwwroot",
                "preloadEnabled": false
            }
        ],
        "loadBalancing": "LeastRequests",
        "experiments": {
            "rampUpRules": []
        },
        "autoHealEnabled": false,
        "localMySqlEnabled": false,
        "ipSecurityRestrictions": [
            {
                "ipAddress": "Any",
                "action": "Allow",
                "priority": 1,
                "name": "Allow all",
                "description": "Allow all access"
            }
        ],
        "scmIpSecurityRestrictions": [
            {
                "ipAddress": "Any",
                "action": "Allow",
                "priority": 1,
                "name": "Allow all",
                "description": "Allow all access"
            }
        ],
        "scmIpSecurityRestrictionsUseMain": false,
        "http20Enabled": false,
        "minTlsVersion": "1.2",
        "ftpsState": "AllAllowed",
        "reservedInstanceCount": 0
    }
},

The error I get though is:

{
    "Code": "BadRequest",
    "Message": "The parameter LinuxFxVersion has an invalid value.",
    "Target": null,
    "Details": [
        {
            "Message": "The parameter LinuxFxVersion has an invalid value."
        },
        {
            "Code": "BadRequest"
        },
        {
            "ErrorEntity": {
                "ExtendedCode": "01007",
                "MessageTemplate": "The parameter {0} has an invalid value.",
                "Parameters": [
                    "LinuxFxVersion"
                ],
                "Code": "BadRequest",
                "Message": "The parameter LinuxFxVersion has an invalid value."
            }
        }
    ],
    "Innererror": null
}

I'm not sure why since this is using the exported from the previously created appservice.I can create this manually through the portal with the correct runtime, but can't get it to work with the arm template. Is the exported linuxFX version is invalid is there somewhere I can get the valid ones that I may have missed. In the docs, I only saw the type rather than an enum of allowed values: https://learn.microsoft.com/en-us/azure/templates/microsoft.web/2018-11-01/sites/config

4c74356b41
  • 69,186
  • 6
  • 100
  • 141
Jacob
  • 1
  • 1
  • I'm not 100% sure this will help (99% sure). if it doesnt. ping me here in the comments. I'll reopen – 4c74356b41 Jan 23 '20 at 06:06
  • linuxFxVersion would be application for Linux App Services. From the ARM Template which you are using, it seems to have been exported it for a Windows App Service. – Gaurav Kumar Jan 23 '20 at 06:56

0 Answers0