FAQ
Hi

for my dns servers the manifest (defines for the zones and keys) gets
pretty long. I have the same problem with my icinga configuration (host and
service checks, for hosts not running puppet (like switches and routers)
where I cannot use exported resources). I know I can put individual nodes
into separate .pp files I've already done that. What I am looking for is
some sort of simple inline include. Is there such a concept or maybe an
other way to simplify node definition.


My manifests look like this:

node dns-master-servers inherits... {
nsd::key { "key-name":
algorithm => "hmac-sha256",
secret => "random sha256 key",
}
nsd::key { ... # about 20 of those
}

nsd::zone { "example.com":
slaves => $nsd_slaves,
key => "key-name",
}

nsd::zone { ... # about 100 of those
}

}


Regards


--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

  • Jared Curtis at Feb 2, 2013 at 4:25 pm
    Couldn't you just add a new include to sites.pp called zones.pp then build a class within it to include on your DNS nodes?

    class myzones {
    nsd::zone { ... }
    .....
    }

    node DNS {
    include myzones
    .....
    }

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To post to this group, send email to puppet-users@googlegroups.com.
    Visit this group at http://groups.google.com/group/puppet-users?hl=en.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Jcbollinger at Feb 4, 2013 at 3:53 pm

    On Saturday, February 2, 2013 10:25:14 AM UTC-6, Jared Curtis wrote:
    Couldn't you just add a new include to sites.pp called zones.pp then build
    a class within it to include on your DNS nodes?

    class myzones {
    nsd::zone { ... }
    .....
    }

    node DNS {
    include myzones
    .....
    }


    Moving the resources out of node blocks and into classes is certainly the
    way to approach the problem. Sites.pp should have nothing to do with it,
    however, and (separately) the new class(es) should go in a module.


    John

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To post to this group, send email to puppet-users@googlegroups.com.
    Visit this group at http://groups.google.com/group/puppet-users?hl=en.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Andre Keller at Feb 4, 2013 at 11:08 pm
    Hi


    thank you for your inputs.

    Am 04.02.2013 16:53, schrieb jcbollinger:
    On Saturday, February 2, 2013 10:25:14 AM UTC-6, Jared Curtis wrote:

    Couldn't you just add a new include to sites.pp called zones.pp
    then build a class within it to include on your DNS nodes?


    and (separately) the new class(es) should go in a module.
    I've done that now and grouped the entries using child classes:

    class myzones {
    include myzones::customer1
    }

    class myzones::customer1 {
    nsd::zone { ... }
    }

    etc..

    That's more or less what I was looking for.

    Is there a way to automatically include child classes? Something like
    include myzones::* :-)


    Regards



    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To post to this group, send email to puppet-users@googlegroups.com.
    Visit this group at http://groups.google.com/group/puppet-users?hl=en.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Jcbollinger at Feb 5, 2013 at 2:07 pm

    On Monday, February 4, 2013 4:40:19 PM UTC-6, Andre Keller wrote:

    Is there a way to automatically include child classes? Something like
    include myzones::* :-)
    No, not as such.


    John


    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To post to this group, send email to puppet-users@googlegroups.com.
    Visit this group at http://groups.google.com/group/puppet-users?hl=en.
    For more options, visit https://groups.google.com/groups/opt_out.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedFeb 2, '13 at 1:12p
activeFeb 5, '13 at 2:07p
posts5
users3
websitepuppetlabs.com

People

Translate

site design / logo © 2022 Grokbase