Links

Overriding DNS

How to override name server resolution in Floods
Sometimes your test scripts will point to DNS records that either aren't public or have specific IP addresses. You can override DNS by uploading a .hosts file with your test plan. It doesn't matter what you call the file, as long as it has the extension .hosts for example, demo.hosts
In this file you can then specify an IP address to return for any host in the given domains. Queries in the domains are never forwarded and always replied to with the specified IP address which may be IPv4 or IPv6. You can also add wildcards/
For example, address=/#/1.2.3.4 will always return 1.2.3.4 for any query not answered from /etc/hosts or DHCP and not sent to an upstream nameserver. We use Google's nameservers for resolution 8.8.8.8 and 8.8.4.4
One or more domains with no address returns a no-such-domain answer, so address=/example.com/ returns NXDOMAIN for example.com and all its subdomains.
A more common example is just to override a specific subdomain, address=/loadtest-staging.flood.io/52.89.198.212 will return 52.89.198.212 for loadtest-staging.flood.io
You can override multiple entries with multiple lines:
address=/loadtest-staging.flood.io/52.89.198.212
address=/loadtest-dev.flood.io/52.89.198.10