- Lab
- A Cloud Guru
Configure Azure Function Proxies
In this hands-on lab, we will configure an Azure Function proxy.
Path Info
Table of Contents
-
Challenge
Log In to the Azure Portal
Log in to the Azure Portal using the username and password supplied by the lab.
- Open a browser.
- Navigate to the provided Azure Portal URL.
- Use the supplied username and password to authenticate.
-
Challenge
Create the HTTP-Triggered Function
Starting in the Azure dashboard, perform the following tasks:
- Open the navigation menu in the upper-left of the Portal.
- Click All resources
Wait for all the resources to appear.
In the list, click the app service that has a name starting with fa-. This will open the overview page of the function app service.
On the function app overview page, click Functions in the function apps navigation tree on the left of the page.
Click + New function at the top of the empty list of functions.
In the list of triggers, click on HTTP trigger.
Name the function "HttpTrigger1".
Click Create.
Wait for the function code to open in the browser.
-
Challenge
Create the Function Proxy
On the code page for the HTTP-triggered function, click Get function URL near the top of the page. On the popup, click Copy to copy the URL to the clipboard. Close the popup.
In the Function apps navigation tree, click Proxies.
When the empty list of proxies displays, click + New proxy. In the configuration form, enter the following information:
- Name: proxy
- Route template: /myfunc
In the Backend URL field, paste in the function URL copied earlier.
Click Create.
-
Challenge
Run the Function via the Proxy
After the Create function task returns, the field Proxy URL will contain a URL. Click Copy to copy the URL to the clipboard.
Open a new browser tab. Paste the URL into the address bar and press enter.
The browser will display the following:
Please pass a name on the query string or in the request body
The function has been run via the proxy, but we need to add the name parameter to the URL, so add
?name=Me
to the URL and press enter.The browser will then display the following:
Hello, Me
What's a lab?
Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.
Provided environment for hands-on practice
We will provide the credentials and environment necessary for you to practice right within your browser.
Guided walkthrough
Follow along with the author’s guided walkthrough and build something new in your provided environment!
Did you know?
On average, you retain 75% more of your learning if you get time for practice.