# Example: # smokeping::activateclient { : # place => "local", # host => "host" # } define smokeping::activateclient ( $place, $host ) { file { "/etc/smokeping/config.d/Targets-$place-$host": ensure => "present", content => "++ $host\nmenu = $host\ntitle = $host\nhost = $host\n", require => Package["smokeping"] } line { $host : file => "/etc/smokeping/config.d/Targets", line => "@include /etc/smokeping/config.d/Targets-$place-$host", ensure => present, require => Package["smokeping"] } } class smokeping::server { package { "smokeping": ensure => installed } service { "smokeping": enable => true, ensure => running, subscribe => [ Package["smokeping"] ], } }