How to do it...

Perform the following steps:

  1. Create a package file for the application. I'm using the same application that we created in Chapter 4, Understanding the Integrated Developer Experience of Visual Studio Tools.
  2. Navigate to the location where you see the bin folder along with other files related to your functions. Create a .zip file out of the files, which is highlighted in the following screenshot:

  1. Create a Blob container (with private access) and upload the package file either from the portal or by using Azure Storage Explorer. 
  2. The next step is to generate a shared access signature (SAS) token for the Blob Container so that Azure Function runtime has the required permissions to access the files located in the container. You can learn more about SAS at https://docs.microsoft.com/en-us/azure/storage/common/storage-dotnet-shared-access-signature-part-1:

  1. Navigate to the Application settings of the function app that we created, and create a new app setting with the WEBSITE_RUN_FROM_PACKAGE key and the value to be the Blob SAS URL that you created in the previous step, as shown here. Click on Save to save the changes:

  1. That's it. After the preceding configuration, you can test the function: