Hi everybody! 

I've the task to migrate our existing puppet installation from Puppet 3.8 
to Puppet 6.x and my colleague gave me the following tasks to do this:

- Hiera: all nodes should be configurable via hiera --> as with our 
currently installed version which has the following configuration:

---
:hierarchy:
  - "nodes/%{::fqdn}"
  - common
:backends:
  - yaml
:yaml:
  :datadir: "/etc/puppet/environments/%{::environment}/hieradata"

- integrate to hiera-levels: 1. One for "common" (valid for all nodes of 
the env) ---> have a look at the code above
                                     2. One per Client-Name 

- NTP should be configured - the IP addresses of the NTP servers on the 
"common" should be taken over and overwritten by the "Node-Config" if 
necessary

- under /var/tmp/ the directory "common" should be created uniformly

- For each node, create a file under "/var/tmp/common" that has the 
hostname (FQDN) of the respective node. The content of the file should be 
the configured NTP-server.

Especially at the last point I have problems to implement this with puppet.

So far I've done the following:

- Created the *site.pp* under* 
/etc/puppetlabs/code/environments/production/manifests *with the following 
content:

Code hier eingeben...node default {
  class { 'ntp':
    servers => [
      'nist-time-server.eoni.com',
      'nist1-lv.ustiming.org',
      'ntp-nist.ldsbc.edu'
    ],
    service_enable => true,
    service_ensure => 'running',
  }
  file { '/var/tmp/common':
    ensure => 'directory'
  }

}

- Create an *hiera.yaml* under */etc/puppetlabs/puppet* with the following 
content:

---
# Hiera 5 Global configuration file

version: 5

defaults:
  datadir: "/etc/puppet/environments/%{::environment}/hieradata"
  data_hash: yaml_data
hierarchy:
 - name: "Common"
   path: "common.yaml"
   data_hash: yaml_data

 - name: "Clients"
   path: "nodes/%{::fqdn}"
# hierarchy: []

Hope, all of you can give me good tipps how I can solve my taks!

Thanks a lot for your help :)

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/9e64de29-f7c9-4c51-996f-41aec7843911%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to