do_dns
Takes the current droplet public IP and creates a Digital Ocean DNS record with it.
Version information
released Nov 4th 2016
This version is compatible with:
- ,
Start using this module
Add this module to your Puppetfile:
mod 'andrewwippler-do_dns', '0.2.0'
Learn more about managing modules with a PuppetfileDocumentation
andrewwippler/do_dns — version 0.2.0 Nov 4th 2016
Table of Contents
- Overview
- Description
- Setup - The basics of getting started with do_dns
- Usage - Configuration options and additional functionality
- Reference
- Limitations
- Development - Guide for contributing to the module
Overview
Grabs the Digital Ocean public IP address and points it to a Digital Ocean DNS record using the $::hostname
fact.
Module Description
Uses the Digital Ocean metadata of your droplet and issues an api curl command to set the dns record based on the droplet's hostname.
Setup
What do_dns affects
- creates /usr/local/bin/set_do_dns.sh and executes it.
Usage
class {'do_dns':
api_key => 'xxxxx',
dns_zone => 'domain.tld',
}
This will ensure $::hostname.domain.tld
points to this droplet.
Reference
api_key
This is your Digital Ocean API key for managing DNS records
dns_zone
This is the domain zone you want to update.
filename (optional)
This is an optional setting. Configures the filename of the script to execute. Useful if you need to update the DNS record.
Limitations
Only works on Digital Ocean Droplets and Digital Ocean DNS. Requires curl
and Puppet 4.x (or 3.5+ with future parser).
Development
See CONTRIBUTING.md
2016-09-16 Release 0.1.0
- Initial creation
Dependencies
- puppetlabs-stdlib (>= 1.0.0)
The MIT License (MIT) Copyright (c) 2016 Andrew Wippler Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.