Filter by IP
If you want to run internal tests from your office/site IP addresses, you can filter out requests originating from a specific IP address.
TO define an IP address you want to filter:
- Open the PX_CUSTOM.vcl fie.
- Add the required IP as a regex expression using req.http.Fastly-Client-IP.
EXAMPLE
To learn more about custom subroutines, see Customized subroutines.
TO enable the feature:
- Open the PX_CONFIG.vcl file.
- Set the px_filter_by_ip_enabled value to “true” (enabled). The default is “false” (disabled).
Test
- Send a request that includes the filtered IP.
- Openthe console and search for your request. If you can’t find the request, the feature is configured correctly.