How it works...
In the preceding task, we are creating a new type A DNS record app.example.com; under zone example.com and mapping it to multiple IP addresses.
We have used the parameter ttl (time to live), which can be seen as the lifespan or lifetime that a record can stay with the client without initiating a new DNS query for the same DNS record.
In the second task, we are retrieving an existing DNS record using a parameter called state with the input value get and registering the value we obtain in the variable name record. And later, in the third task, once we have that DNS record information in the variable, using the state parameter with the value absent, we delete that DNS record.
We should note that once we register the DNS record ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access