How to instantiate edge functions in your edge firewall

Instantiate serverless functions directly within your edge firewall.

This guide uses the configured Deny a request based on Geoip function. You can repeat this process using any function already available on Azion Marketplace or develop other functions.

This guide will also presume you have a network list of the Countries type.


  1. Access Azion Console > select Edge Firewall.
  2. Click the edge firewall you want to configure.
  3. In the Main Settings tab, enable the Edge Functions module switch to enable functions.
  4. Click the Save button.
  5. Go to the Functions Instances tab.
  6. Click + Function Instance.
  7. Name your function instance. For example: Deny Geoip function.
  8. On the Edge Functions dropdown, select the function you want to use. In this example, Deny Geoip function.
  • If you want, you can edit the Arguments.
  1. Click the Save button.

The functions page now lists the newly created instance. However, this new function isn’t yet active in your application. You need to define what will trigger the function.

Still on the Edge Firewall page:

  1. Navigate to the Rules Engine tab.
  2. Click the + Rule button.
  3. Give a name to your rule.
  4. Under the Criteria section, select the variable Network.
  5. As a comparison operator, select matches.
  6. As an argument, select the network list of the Countries type you want to use. For example: Blocked Countries Geoip.
  7. In the Behaviors section, select Run Function from the behavior list.
  8. Select the function you want to use. In this example, Deny Geoip function.
  9. Click the Save button.

Once your application receives a request generated from one of the countries in the network list, the function in your firewall will deny the request based on the geo IP.



Contributors