Ask Your Question

PuppetDB & templatedir

asked 2016-01-02 01:01:43 -0600

nobody gravatar image

updated 2016-01-02 01:02:36 -0600

Hi there! I installed some puppet server and puppetDB: this man and now i have some questions:

  1. How to know than puppetDB is work? I can't see it in 'ps ax' output: that's ok?
  2. Where i can set templatedir? In puppet 3.8 it's done in /etc/puppet/puppet.conf, but in this version i dunno where is this set...
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2016-01-06 04:35:35 -0600

nobody gravatar image

updated 2016-01-06 04:36:31 -0600

I find answer. All templates now store in /etc/puppetlabs/code/modules/ and if i want run this expression

    file { '/usr/local/sbin/':
        ensure => file,
        content => template(""),
        mode => 0555,

i must:

  1. mkdir /etc/puppetlabs/code/modules/herota
  2. mkdir /etc/puppetlabs/code/modules/herota/templates
  3. Create in /etc/puppetlabs/code/modules/herota/templates/
  4. Use:

    file { '/usr/local/sbin/':
        ensure => file,
        content => template("herota/"),
        mode => '0555',

P.S. mode now must be in single quotes (ex. mode => '0555')

P.S. [2] Documentation is not absolutely clear. I'm lucky and just guessing that FACEPALM

edit flag offensive delete link more

answered 2016-01-03 07:16:00 -0600

Q1: Puppet DB is a Java process with an init/systemctl script. Use this to check the status of the puppetDB. Please keep in mind that per default config the puppet server and the puppetDB will both require 2 GB heap size!

Q2: templatedir setting is deprecated. Templates are now always part of a module:

<module name>/ 
edit flag offensive delete link more


Thank you so much! Q2: Please, could you tell a little more detail? Example, i have in my puppet 3.8 server in config string "templatedir=/etc/puppet/templates" and same manifest: and all is worked. How can i remake this manifest to puppet 4.* ?

nobody gravatar imagenobody ( 2016-01-03 07:51:11 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2016-01-02 01:01:43 -0600

Seen: 257 times

Last updated: Jan 06 '16