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:Add ability to create a Function App or Function key directly

See original GitHub issue

Description

The Azure CLI should be able to create a function-app-scoped or function-scoped key in an Azure Function App via the functionapp subcommand. It should also be able to retrieve existing keys.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:10
  • Comments:22 (13 by maintainers)

github_iconTop GitHub Comments

4reactions
worldspawncommented, Jun 9, 2018

I think the first thing that should happen is have the host keys returned in the result of creating a function app with the cli. Much like when I create storage I get the access keys

3reactions
anthonychucommented, Feb 16, 2020

@ankitkumarr Here’s an attempt at what the commands might look like. Let me know what you think:

Function details and keys:

az functionapp function show --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --function-name $FUNCTION_NAME
az functionapp function list --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME
az functionapp function keys list --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --function-name $FUNCTION_NAME
az functionapp function keys set --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --function-name $FUNCTION_NAME --key-name $KEY_NAME --key-value $KEY_VALUE
az functionapp function keys delete --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --function-name $FUNCTION_NAME --key-name $KEY_NAME

Host keys (unsure how this would work with systemKeys and functionKeys):

az functionapp keys list --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME
az functionapp keys set --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --key-name $KEY_NAME --key-value $KEY_VALUE
az functionapp keys delete --resource-group $RESOURCE_GROUP --name $APP_NAME --slot $SLOT_NAME --key-name $KEY_NAME
Read more comments on GitHub >

github_iconTop Results From Across the Web

Configure function app settings in Azure Functions
To add a setting in the portal, select New application setting and add the new key-value pair. Function app settings in the Azure...
Read more >
Setting the Function Key - Common Problems
In the below Powershell script I am setting the values for setting up a key for the function app from a devops pipeline....
Read more >
[Question] Functions 'Host Keys' & ARM templates #516 - GitHub
Hi, We utilize the Host Keys to protect functions. ... Is the ability to provision function app host keys (and individual function keys...
Read more >
How to create a Azure Function, Function Key when your ...
Found this interesting article on how to manage azure functions keys from Powershell : Manage Azure Functions Keys.
Read more >
Using Azure Key Vault references with Azure Functions or App ...
If you are already familiar with Azure Key Vault, App Service/Functions and ... function OR you could just create the function directly in...
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