Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Template as an option in addition to db.empty for zone. #101

Open
claflico opened this issue Sep 20, 2016 · 3 comments
Open

Comments

@claflico
Copy link

Would it be possible to get functionality added to use a template here rather than a static file: https://github.com/inkblot/puppet-bind/blob/master/manifests/zone.pp#L111

I'm trying to use your module to setup a split-dns for both private & public websites we are hosting and I'd like to try it with a template instead so that I don't have to maintain multiple zone records.

@inkblot
Copy link
Owner

inkblot commented Nov 5, 2016

It would be possible, but it would also be possible to do this using resource_record resources in a puppet define. This is how I do split-dns with public and private zones. I have a site::dns class which declares the views, zones, acls, and keys. This class also defines the DNS resource records which are different between the public and private zones, and includes two declarations of a site::dns::common define. In this define are all of the records (defined using resource_record) that are the same between the public and private zones, and the define is parameterized to place the records in one zone at a time, but used twice in the class, once for each zone.

@WetHippie
Copy link

I'm another looking for templates in the bind::zone class in order to bootstrap the zone into existence. We have some fairly dynamic internal zone creation so allowing us to template this and drop in new zones based on hiera/PuppetDB definitions would make our lives a lot easier. I'll put together a pull request for you in the next day or two. Should be pretty easy.

@WetHippie
Copy link

Sorry for the delay. Pull request sent for this feature. A very simple implementation that just preferences the file content rather than a source reference if not empty.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants