Share via


Azure Portal Environment Tips

Working with Functions in the Azure portal

Functions can be created, configured, and tested in the Azure portal. To create a function, you must first create a Function App to host execution of functions. This can be found by clicking the + button in the top left corner and searching for Function App in the Marketplace.

Creating a function app

Once configured and created, navigate to the new function app, expand it, and click the + button next to Functions. Select a function to create and the language, and click "Create this function." This example works with a generic HTTP function trigger.

Creating a function

In the portal view of the function, the left side has a list of the editable function files and a test view. Function files can be edited in the portal and also tested by clicking the "Run" button at the bottom of the test view.

A function in the portal

Takeaways

  • Functions can be created, and tested in the Portal.
  • Function apps host functions.

Read more

Allowing HTTP verbs in the Azure portal

If you want to control which HTTP verbs are available for your function in the Azure portal, access your function's integrate tab.

Azure Functions expanded tab in the portal

On the integrate page under "Allowed HTTP methods", you can choose either All methods or Selected methods. If you select All methods, there isn't anything else to do. With selected methods, eight checkboxes appear for you to customize access to your app:

Azure Functions HTTP methods inside the portal

Takeaways

  • Controlling HTTP verb permissions for your function can be as easy as changing a few settings in the integrate tab in the Azure portal.

Read more

Getting your function and host keys in the Azure portal

If your function's authorization is set to function or admin, all requests must contain the function key or the host key to access them. To get to your keys in the Azure portal, go to the management tab for the function.

Azure Functions Manage tab

On the manage page you will see your function keys, as well as options to create, remove, or update any function keys.

Azure Functions Manage page

Host keys are identical across functions in the same function app, but function keys are unique to each function.

Takeaways

  • Keys can be accessed and managed in the manage tab of your function in the Azure portal.
  • Every function has its own function key, but every function in a function app shares a host key.

Read more

More on keys and what they are used for

Controlling how much your function can run in one day

Azure Functions measures the run time of functions in GB-seconds. To avoid being overbilled, Azure Functions gives the user the ability to set Daily Usage Quotas for their function apps. When an app hits the quota, it will cease to run until midnight UTC. To set this limit, first access your app in the Azure portal, and navigate to the Overview tab.

Azure Functions Overview tab in the portal

Click through to the Function app settings page to get to the Daily Usage Quota (GB-sec) field. From there, you can enter your desired quota in GB-seconds.

Azure Functions Application Settings in the portal

Takeaways

  • A function's use is measured in GB-seconds
  • Azure Functions can have their usage limited by the Daily Usage Quota setting in the function app settings.

Read more