Net::Amazon::R53 - An interface to Amazon's Route53
This document describes version 0.002 of Net::Amazon::R53 - released January 09, 2013 as part of Net-Amazon-R53.
use Net::Amazon::R53;
my $r53 = Net::Amazon::R53->new(id => $aws_id, key => $aws_key);
$r53
->get_hosted_zone('Z1345....')
->purge
->delete
;
# ...etc.
This is an interface to Amazon's Route53 DNS service. It aims to be simple, reliable, well tested, easily extensible, and capable of rescuing kittens from volcanoes.
Well, maybe not that last part.
These attributes are required, and must have their values supplied during object construction.
Your AWS id.
...and the corresponding AWS secret key.
These attributes are lazily constructed from another source (e.g. required attributes, external source, a BUILD() method, or some combo thereof). You can set these values at construction time, though this is generally neither required nor recommended.
The logic that authenticates your requests to Route53.
Contains a list of all HostedZones
associated with this AWS key/id; lazily built. Right now we fetch at most 100 records.
The directory we expect to find our templates in.
Returns a list of headers (key/value pairs) suitable for direct inclusion in the headers of a Route53 request.
True if the hosted_zones
attribute is currently populated (that is, we've fetched some at some point from Amazon.
Deletes our cached set of hosted zones, if we have any.
True if we currently have any hosted zones.
True if we have a zone with a plain id as passed to us.
Returns all of the hosted zone ids we know about.
Returns a list of all known hosted zones; that is, a list of Net::Amazon::R53::HostedZone instances.
Returns the number of hosted zones Route53 thinks we have. =method hosted_zone_by_id($id)
Looks for a hosted zone with the passed value as its id. Note that we're talking about the so-called "plain" id, not the fully qualified one (e.g. 'Z12345', not '/hostedzone/Z12345').
Looks for a zone with the passed string as its caller reference. Returns nothing if no such zone is found.
Given a hosted zone id, we fetch all its associated resource record sets.
Creates a hosted zone.
name
is the domain name this zone holds records for, e.g. 'test.com.'.
caller_reference
is some unique client-chosen (aka you) identifier.
comment
is, well, the comment used for zone creation.
Only the name
parameter is mandatory; suitable values will be generated for the other options if they are omitted.
Returns the new hosted zone object if called in scalar context; the change and hosted zone objects if called in list context; that is:
my ($hz, $change) = $r53->create_hosted_zone(...);
my $hz = $r53->create_hosted_zone(...);
Dies on error. For more information, see the Route53 API and Developer's Guide.
Given a hosted zone object, create a new hosted zone and copy the contents of the given zone to the new zone.
Returns the new hosted zone instance.
Delete a hosted zone, by its id; both the plain id (e.g. ZIQB30DSWGWG6
) or the full one Amazon returns (e.g. /hostedzone/ZIQB30DSWGWG6
) are acceptable ids.
We do not perform any validation. If the zone doesn't exist, or is not pristine (contains any non-Amazon record sets), or anything else goes sideways, we'll just die.
Make a request to Route53.
Same as request(), but as a GET.
Same as request(), but as a POST.
Same as request(), but as a DELETE.
Please see those modules/websites for more information related to this module.
Chris Weyl <[email protected]>
Chris Weyl <[email protected]>
This software is Copyright (c) 2012 by Campus Explorer, Inc.
This is free software, licensed under:
The GNU Lesser General Public License, Version 2.1, February 1999
Hey! The above document had some coding errors, which are explained below:
- Around line 188:
-
Nested L<> are illegal. Pretending inner one is X<...> so can continue looking for other errors.
Nested L<> are illegal. Pretending inner one is X<...> so can continue looking for other errors.