serverless-azure-functions icon indicating copy to clipboard operation
serverless-azure-functions copied to clipboard

Consumption AppServicePlan return InvalidTemplateDeployment

Open atibi opened this issue 5 years ago • 2 comments

This is a Bug Report

Description

  • What went wrong?

In the last 2 days, when deploying a new function, the provisioning phase throw an error on the app service plan ARM template: Operation name: Create Deployment Error code: InvalidTemplateDeployment Message: The template deployment 'slsweurdevmytest-DEPLOYMENT-t1575644636913' is not valid according to the validation procedure. The tracking id is '31248f05-6aae-4996-b42f-eda5fe754505'. See inner errors for details. Forcing consumption plan to provide a default ARM template (like the plugin do with the premium one) works as expected and correctly creates the function.

  • What was the config you used?
provider:
  prefix: sls
  name: azure
  runtime: nodejs10.x
  region: westeurope
  stage: dev
  functionApp:
    name: mytest-dev
  appServicePlan:
    name: WestEuropePlan
  • What stacktrace or error message from your provider did you see?

From the activity log of the resource group on Azure portal: "properties": { "statusCode": "BadRequest", "serviceRequestId": null, "statusMessage": "{\"error\":{\"code\":\"InvalidTemplateDeployment\",\"message\":\"The template deployment 'slsweurdevmytest-DEPLOYMENT-t1575644636913' is not valid according to the validation procedure. The tracking id is '31248f05-6aae-4996-b42f-eda5fe754505'. See inner errors for details.\",\"details\":[{\"code\":\"ValidationForResourceFailed\",\"message\":\"Validation failed for a resource. Check 'Error.Details[0]' for more information.\",\"details\":[{\"code\":\"51008\",\"message\":\"The parameter validateRequest.Properties.SkuName has an invalid value.\"}]}]}}"

Additional Data

  • Serverless Framework Version you're using: 1.59.2
  • Serverless CLI Version you're using:
  • Serverless Azure Plugin Version you're using: 1.0.2-16
  • Operating System: macOS Catalina
  • Stack Trace:
  • Provider Error messages:

atibi avatar Dec 07 '19 09:12 atibi

@atibi could you retry with latest and confirm if you're still seeing this issue?

tbarlow12 avatar Jun 09 '20 14:06 tbarlow12

I'm looking for information and I don't know if this issue helps me.

I need to specify the function plan that I'm going to use as per consumption, but I didn't find anything in the documentation.

Can anyone help?

rodrigoaraujo1 avatar Jul 26 '21 21:07 rodrigoaraujo1