Steps On Puppet Master: Puppet Environment Structure: Manifest
Steps On Puppet Master: Puppet Environment Structure: Manifest
Example:
class profile::git {
include ::git
}
class role::scm
{
include ::profile::git
}
→ /etc/puppet/ # vi hiera.yaml
---
? !ruby/symbol backends
:
- yaml
? !ruby/symbol hierarchy
:
- scm
? !ruby/symbol yaml
:
? !ruby/symbol datadir
: /etc/puppet/hieradata
---
:backends:
- yaml
:yaml:
:datadir: "/etc/puppet/hieradata"
:hierarchy:
- scm
Install puppet-lint ---- to check paths of manifest
cd hieradata
vi scm.yaml
Create a site.pp
→# cd /etc/puppet/manifests
vi site.pp

node "puppetagent-1.test.org" {
hiera_include('classes')
# package { 'git':
# name => 'git',
# ensure => installed,
#}
}
Copy all yamal code and paste in that site then click on go - it check any syntax errors .
If there is wrong it correct and display --- how it show i show in video.
Steps For Puppet agent
# puppet agent -t
Tree :
# /etc/puppet/modules/ Profiles/manifest/git.pp
role/ manifest/scm.pp
#/etc/puppet/ hiera.yaml
hieradata/scm.yaml
# /etc/puppet/manifests/site.pp
On puppet agent
http://www.unixarena.com/2016/02/puppet-manifest-example-updating-files-on-agent-
nodes.html
http://www.yamllint.com/
https://forge.puppet.com/Aethylred/git
https://forge.puppet.com/example42/apache