question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

functionapp: az cli disables build on deploy for windows function apps

See original GitHub issue

Describe the bug https://github.com/Azure/azure-cli/pull/10706 effective disables remote builds for windows consumption plan function apps.

Changelog does not mention that new flag is for linux function apps only:

Added --build-remote flag for az functionapp deployment source config-zip to support remote build action during function app deployment.

Also no deprecation warning for have been given for windows consumption plan with SCM_DO_BUILD_DURING_DEPLOYMENT=true

Documentation[1] does not specify any ways to trigger npm install.

To Reproduce Running az functionapp deployment source config-zip --build-remote ... fails with Remote build is only available on Linux function apps

Alternative running az functionapp deployment source config-zip without --build-remote flag changes function app settings and does not trigger npm install:

Setting ENABLE_ORYX_BUILD to false
Setting SCM_DO_BUILD_DURING_DEPLOYMENT to false

Expected behavior After zip deployment function host should trigger npm install(or other installation method) like az cli did before the pull request.

Alternative fix: another way to trigger npm install after deployment with az cli should be documented.

Environment summary

azure-cli                          2.1.0

command-modules-nspkg              2.0.3
core                               2.1.0
nspkg                              3.0.4
telemetry                          1.0.4

Additional context

[1] https://docs.microsoft.com/en-us/azure/azure-functions/functions-deployment-technologies#remote-build

Workrounds

  • Trigger npm install manually in kudu console
  • fetch publishing profile with az cli and trigger npm install through kudu REST API

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:11 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
panchagnulacommented, Nov 2, 2021

@StrawnSC can you investigate - AFAIK no changes were to function app deployment that should regress this.

1reaction
mortezasoftcommented, Oct 23, 2020

What is the latest status of this issue? I have the same issue with the latest version of Azure CLI.

Read more comments on GitHub >

github_iconTop Results From Across the Web

az functionapp | Microsoft Learn
Create a function app. The function app's name must be able to produce a unique FQDN as AppName.azurewebsites.net. Azure CLI
Read more >
az functionapp deployment source | Microsoft Learn
Disable automatic sync between source control and web. --name -n. Name of the function app. --repository-type. Repository type.
Read more >
How to disable functions in Azure Functions - Microsoft Learn
Azure CLI; Azure PowerShell. Navigate to the slot instance of your function app by selecting Deployment slots under Deployment, choosing your ...
Read more >
az functionapp config | Microsoft Learn
Bind an SSL certificate to a function app. az functionapp config ssl create. Create a Managed Certificate for a hostname in a function...
Read more >
az functionapp - Microsoft Learn
az functionapp create. Create a function app. The function app's name must be able to produce a unique FQDN as AppName.azurewebsites.net. Azure CLI...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found