#Puppet

Declarative configuration management.


#Overview

ComponentDescription
Puppet MasterCentral server
Puppet AgentRuns on nodes
ManifestsConfiguration files
ModulesReusable components

#Manifest Example

puppet
1# manifests/site.pp
2node 'webserver' {
3  package { 'nginx':
4    ensure => installed,
5  }
6
7  service { 'nginx':
8    ensure  => running,
9    enable  => true,
10    require => Package['nginx'],
11  }
12
13  file { '/etc/nginx/nginx.conf':
14    ensure  => file,
15    content => template('myapp/nginx.conf.erb'),
16    notify  => Service['nginx'],
17  }
18}

#Commands

bash
1# Apply manifest
2puppet apply manifest.pp
3
4# Agent run
5puppet agent -t
6
7# Parse/validate
8puppet parser validate manifest.pp

#Strengths

  • Strong declarative model
  • Enterprise features
  • Mature ecosystem

[!TIP] Pro Tip: Puppet excels in large, stable enterprise environments!