poshbotio / PoshBot

Powershell-based bot framework

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FunctionApp creation not working as expected

bobalob opened this issue · comments

Function App shows an error relating to unknown language [dotnet]. Also the Function does not run as expected, complaining about Push-OutputBinding not being a known command.

Current Behavior

When running the following command, the FunctionApp is created but the PowerShell commandlet Push-OutputBinding is not available and there is a warning in the Overview section relating to [dotnet]

az functionapp create --resource-group <RESOURCE-GROUP-NAME> --name <FUNCTION-APP-NAME> \
  --storage-account <STORAGE-ACCOUNT-NAME> --consumption-plan-location <REGION> \
  --deployment-source-url "https://github.com/poshbotio/TeamsWebhook"

Possible Solution

add the following to the az functionapp create command

--runtime powershell

Thanks for reporting this @bobalob.

I haven't tested this yet, but it looks like behavior change in az functionapp. The docs were written when v1 functions were still the default.

@bobalob Docs have been updated to include --runtime powershell and --functions-version 3.