Creating and testing Azure functions locally using Azure CLI tools
Most of the recipes so far have been created using either the browser or the Visual Studio integrated development environment (IDE).
Azure also provides tools for developers who prefer to work with the command line. These tools allow us to create Azure resources with simple commands right from the command line. In this recipe, we'll learn how to create a new function app, and we'll also understand how to create a function and deploy it to Azure directly from the command line.
Getting ready
Before proceeding further with the recipe, install Node.js and the Azure CLI. The download links for these tools are as follows:
- Download and install Node.js from https://nodejs.org/en/download/.
- Download and install Azure Functions Core Tools (also known as the Azure CLI) from https://docs.microsoft.com/azure/azure-functions/functions-run-local?tabs=windows%2Ccsharp%2Cbash.