Skip to content

Instantly share code, notes, and snippets.

@EmmanuelKasper
Last active January 3, 2016 20:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EmmanuelKasper/8518848 to your computer and use it in GitHub Desktop.
Save EmmanuelKasper/8518848 to your computer and use it in GitHub Desktop.
A canonical puppet deployment file, based on the package / file /service hierarchy
class amanda {
package { "amanda-client":
ensure => installed,
before => File['/etc/amandahosts'],
}
file { "/etc/amandahosts":
ensure => file,
owner => "backup",
group => "backup",
mode => 0600,
source => "puppet:///files/amandahosts",
}
file { "/etc/amanda.exclude-list":
ensure => file,
owner => "root",
group => "root",
mode => 0644,
replace => false,
source => "puppet:///files/amanda.exclude-list",
}
package { "openbsd-inetd":
ensure => installed,
before => File['/etc/inetd.conf'],
}
file { "/etc/inetd.conf":
ensure => file,
owner => "root",
group => "root",
mode => 0644,
source => "puppet:///files/inetd.conf",
}
service { "openbsd-inetd":
ensure => running,
enable => true,
pattern => "/usr/sbin/inetd",
subscribe => File['/etc/inetd.conf'],
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment