From 7ea9ad17cab2544875d4934a90522dd74f0b6396 Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 20 Feb 2011 13:13:37 +0100 Subject: treat case where host is not in stored configs so far --- files/master/lastruncheck | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/files/master/lastruncheck b/files/master/lastruncheck index 420730f..babe74f 100644 --- a/files/master/lastruncheck +++ b/files/master/lastruncheck @@ -96,7 +96,9 @@ module Puppet::Lastcheck::Tests::Storedconfigs storedconfigs_hosts.each do |host| if !facts_hosts.any?{|fact_host| fact_host[:hostname] == host.name } add_failed_host(host.name, "In storedconfigs but no facts available!") - elsif host.last_compile.nil? || host.last_compile < (Time.now - @timeout) + elsif host.last_compile.nil? + add_failed_host(host.name, "No entry in storedconfigs") + elsif host.last_compile < (Time.now - @timeout) add_failed_host(host.name, "Last compile time in storedconfigs at #{host.last_compile}") end end -- cgit v1.2.3 From 84d4ee9db697e35299b5c9d157bb818af1088416 Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 3 Apr 2011 14:12:05 +0200 Subject: fix lastruncheck to be compatible for 2.6.7 --- files/master/lastruncheck | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/files/master/lastruncheck b/files/master/lastruncheck index babe74f..9eff27e 100644 --- a/files/master/lastruncheck +++ b/files/master/lastruncheck @@ -23,9 +23,11 @@ module Puppet::Lastcheck def facts_hosts return @facts_hosts if @facts_hosts require 'puppet/indirector/facts/yaml' - @facts_hosts = Puppet::Node::Facts.search("*").collect do |node| - { :hostname => node.name, :expired => node.expired?, :timestamp => node.values[:_timestamp], :expiration => node.expiration } - end + @facts_hosts = Puppet::Node::Facts.search("*").collect do |fqdn| + if node = Puppet::Node::Facts.search(fqdn) + { :hostname => node.name, :expired => node.expired?, :timestamp => node.values[:_timestamp], :expiration => node.expiration } + end + end.compact end end end -- cgit v1.2.3 From 4a5a3d04a8e45cb7666e3c270b9a3ae7a4786a70 Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 3 Apr 2011 14:39:17 +0200 Subject: find not search --- files/master/lastruncheck | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/master/lastruncheck b/files/master/lastruncheck index 9eff27e..fe67d21 100644 --- a/files/master/lastruncheck +++ b/files/master/lastruncheck @@ -24,7 +24,7 @@ module Puppet::Lastcheck return @facts_hosts if @facts_hosts require 'puppet/indirector/facts/yaml' @facts_hosts = Puppet::Node::Facts.search("*").collect do |fqdn| - if node = Puppet::Node::Facts.search(fqdn) + if node = Puppet::Node::Facts.find(fqdn) { :hostname => node.name, :expired => node.expired?, :timestamp => node.values[:_timestamp], :expiration => node.expiration } end end.compact -- cgit v1.2.3 From 05a9d526ab7a23dea30058dbb3ac21a9bb521dab Mon Sep 17 00:00:00 2001 From: mh Date: Sun, 17 Apr 2011 17:21:52 +0200 Subject: no need to log to the console as we don't use puppets logging feature --- files/master/lastruncheck | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/master/lastruncheck b/files/master/lastruncheck index fe67d21..149c655 100644 --- a/files/master/lastruncheck +++ b/files/master/lastruncheck @@ -189,7 +189,7 @@ class Puppet::Application::Lastcheck < Puppet::Application def setup exit(Puppet.settings.print_configs ? 0 : 1) if Puppet.settings.print_configs? - Puppet::Util::Log.newdestination :console + #Puppet::Util::Log.newdestination :console Puppet::Node::Facts.terminus_class = :yaml Puppet::Lastcheck::Tests.tests.keys.each do |test| -- cgit v1.2.3 From 618384cf08340b34a4eaf1022d200c1acb8161f4 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Wed, 19 Jan 2011 20:09:16 -0500 Subject: Support puppet client for FreeBSD Some pieces of the puzzle are missing for being able to manage puppet in FreeBSD. * Add a default puppet client config template for FreeBSD * In FreeBSD, puppet.conf is not in /etc/puppet/ so let's provide a value for this variable in init.pp. * The rc script for starting and stopping puppet is not located in /etc/rc.d so let's signify this to Service[puppet] Signed-off-by: Gabriel Filion --- files/client/puppet.conf.FreeBSD | 26 ++++++++++++++++++++++++++ manifests/freebsd.pp | 7 +++++++ manifests/init.pp | 7 +++++++ 3 files changed, 40 insertions(+) create mode 100644 files/client/puppet.conf.FreeBSD create mode 100644 manifests/freebsd.pp diff --git a/files/client/puppet.conf.FreeBSD b/files/client/puppet.conf.FreeBSD new file mode 100644 index 0000000..cd8bd2a --- /dev/null +++ b/files/client/puppet.conf.FreeBSD @@ -0,0 +1,26 @@ +[main] + logdir=/var/log/puppet + vardir=/var/puppet + rundir=/var/run/puppet + + ssldir=/usr/local/etc/puppet/ssl + + # Where 3rd party plugins and modules are installed + libdir = $vardir/lib + + templatedir=$vardir/templates + + # Turn plug-in synchronization on. + pluginsync = true + pluginsource = puppet://$server/plugins + factpath = $vardir/lib/facter + +[puppetd] + report=true + server=server.example.com + + # different run-interval, default= 30min + # e.g. run puppetd every 4 hours = 14400 + # runinterval = 14400 + + logdest=$logdir/puppet.log diff --git a/manifests/freebsd.pp b/manifests/freebsd.pp new file mode 100644 index 0000000..1fe28d0 --- /dev/null +++ b/manifests/freebsd.pp @@ -0,0 +1,7 @@ +class puppet::freebsd inherits puppet::base { + + Service['puppet'] { + path => '/usr/local/etc/rc.d', + } + +} diff --git a/manifests/init.pp b/manifests/init.pp index e9d9748..69d9b18 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -19,6 +19,13 @@ # class puppet { + $puppet_default_config = $kernel ? { + freebsd => '/usr/local/etc/puppet/puppet.conf', + default => '/etc/puppet/puppet.conf', + } + + if $puppet_config == '' { $puppet_config = $puppet_default_config } + case $kernel { linux: { case $operatingsystem { -- cgit v1.2.3 From b333a0ed2561256ff5a2af0cb0e46ea663ac647c Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Sat, 16 Jul 2011 16:39:16 -0400 Subject: Support FreeBSD for the puppet master The puppet master has one additional config file that needs to be placed in a different folder under FreeBSD. Signed-off-by: Gabriel Filion --- manifests/puppetmaster/base.pp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/manifests/puppetmaster/base.pp b/manifests/puppetmaster/base.pp index 6ac1e0c..820e499 100644 --- a/manifests/puppetmaster/base.pp +++ b/manifests/puppetmaster/base.pp @@ -5,7 +5,14 @@ class puppet::puppetmaster::base inherits puppet::base { "puppet:///modules/puppet/master/puppet.conf" ], } - if !$puppet_fileserverconfig { $puppet_fileserverconfig = '/etc/puppet/fileserver.conf' } + # This is not in puppet::puppetmaster since we'd like for + # puppet::puppetmaster::cluster to work in FreeBSD too. + $puppet_default_config_dir = $operatingsystem ? { + freebsd => "/usr/local/etc/puppet", + default => "/etc/puppet", + } + + if !$puppet_fileserverconfig { $puppet_fileserverconfig = "${puppet_default_config_dir}/fileserver.conf" } file { "$puppet_fileserverconfig": source => [ "puppet:///modules/site-puppet/master/${fqdn}/fileserver.conf", -- cgit v1.2.3 From 2a13f8a56b2acac95c9f59f6957eb5ece386e76d Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Tue, 23 Aug 2011 16:11:16 -0400 Subject: FreeBSD: install packages via puppet itself The linux class installs puppet and facter via puppet itself. Chances are that they are already installed, since you need puppet before you can run puppet. _But_, it enables the $puppet_ensure_version and $facter_ensure_version features (forcing the installed version). So let's do the same in FreeBSD. Signed-off-by: Gabriel Filion --- manifests/freebsd.pp | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/manifests/freebsd.pp b/manifests/freebsd.pp index 1fe28d0..3d0995d 100644 --- a/manifests/freebsd.pp +++ b/manifests/freebsd.pp @@ -1,7 +1,18 @@ class puppet::freebsd inherits puppet::base { - Service['puppet'] { - path => '/usr/local/etc/rc.d', - } + if !$puppet_ensure_version { $puppet_ensure_version = 'installed' } + package { 'puppet': + ensure => $puppet_ensure_version, + } + + if !$facter_ensure_version { $facter_ensure_version = 'installed' } + package { 'facter': + ensure => $facter_ensure_version, + } + + Service['puppet'] { + path => '/usr/local/etc/rc.d', + require => Package[puppet], + } } -- cgit v1.2.3 From 529e6ec7a0bfd2d82b0819b50cf2033ae3c91bfc Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Tue, 23 Aug 2011 16:29:38 -0400 Subject: Include the OS-specific class for FreeBSD The FreeBSD class was previously defined but not included by the puppet class in init.pp Signed-off-by: Gabriel Filion --- manifests/init.pp | 1 + 1 file changed, 1 insertion(+) diff --git a/manifests/init.pp b/manifests/init.pp index 69d9b18..fb10773 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -36,6 +36,7 @@ class puppet { } } openbsd: { include puppet::openbsd } + freebsd: { include puppet::freebsd } default: { include puppet::base } } -- cgit v1.2.3 From 56528806115735c1717408989d6d39049574333b Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Tue, 23 Aug 2011 16:30:36 -0400 Subject: Fix ssldir value for FreeBSD config The default ssl directory in FreeBSD is /var/puppet/ssl, not /usr/local/etc/puppet/ssl With the previous value, puppet would refuse to run starting from the second run, stating that the certificates do not match. Signed-off-by: Gabriel Filion --- files/client/puppet.conf.FreeBSD | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/client/puppet.conf.FreeBSD b/files/client/puppet.conf.FreeBSD index cd8bd2a..71bcf77 100644 --- a/files/client/puppet.conf.FreeBSD +++ b/files/client/puppet.conf.FreeBSD @@ -3,7 +3,7 @@ vardir=/var/puppet rundir=/var/run/puppet - ssldir=/usr/local/etc/puppet/ssl + ssldir=/var/puppet/ssl # Where 3rd party plugins and modules are installed libdir = $vardir/lib -- cgit v1.2.3 From 000165503f79e6214047ba2622bdabf4176a68a0 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Tue, 23 Aug 2011 16:53:14 -0400 Subject: Move $puppet_default_config_dir to the puppet class We'd like to use this variable in the 'puppet' class since we're defining the path to another config file, there. Since puppet::puppetmaster inherits the puppet class, the variable will be defined appropriately. Just to make sure we get the value from the right place, let's also use the qualified variable name. To avoid useless repetitions in the variable name, change the variable name from $puppet_default_config_dir to $default_config_dir. Signed-off-by: Gabriel Filion --- manifests/init.pp | 10 ++++++---- manifests/puppetmaster/base.pp | 11 ++--------- 2 files changed, 8 insertions(+), 13 deletions(-) diff --git a/manifests/init.pp b/manifests/init.pp index fb10773..c05631a 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -19,15 +19,17 @@ # class puppet { - $puppet_default_config = $kernel ? { - freebsd => '/usr/local/etc/puppet/puppet.conf', - default => '/etc/puppet/puppet.conf', + $default_config_dir = $operatingsystem ? { + freebsd => "/usr/local/etc/puppet", + default => "/etc/puppet", } + $puppet_default_config = "$default_config_dir/puppet.conf" + if $puppet_config == '' { $puppet_config = $puppet_default_config } case $kernel { - linux: { + linux: { case $operatingsystem { gentoo: { include puppet::gentoo } centos: { include puppet::centos } diff --git a/manifests/puppetmaster/base.pp b/manifests/puppetmaster/base.pp index 820e499..0000513 100644 --- a/manifests/puppetmaster/base.pp +++ b/manifests/puppetmaster/base.pp @@ -5,21 +5,14 @@ class puppet::puppetmaster::base inherits puppet::base { "puppet:///modules/puppet/master/puppet.conf" ], } - # This is not in puppet::puppetmaster since we'd like for - # puppet::puppetmaster::cluster to work in FreeBSD too. - $puppet_default_config_dir = $operatingsystem ? { - freebsd => "/usr/local/etc/puppet", - default => "/etc/puppet", - } - - if !$puppet_fileserverconfig { $puppet_fileserverconfig = "${puppet_default_config_dir}/fileserver.conf" } + if !$puppet_fileserverconfig { $puppet_fileserverconfig = "${puppet::default_config_dir}/fileserver.conf" } file { "$puppet_fileserverconfig": source => [ "puppet:///modules/site-puppet/master/${fqdn}/fileserver.conf", "puppet:///modules/site-puppet/master/fileserver.conf", "puppet:///modules/puppet/master/fileserver.conf" ], owner => root, group => puppet, mode => 640; - } + } if $puppetmaster_storeconfigs { include puppet::puppetmaster::storeconfigs -- cgit v1.2.3 From c0afea193ef40786fb61cbab24f6e9366f157264 Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Tue, 23 Aug 2011 18:04:45 -0400 Subject: Add partial freebsd cron job support The puppet::cron::freebsd class is almost identical to the puppet::cron::openbsd one, but there is no cron job to remove, and the /etc/rc.conf mechanism doesn't exist yet for FreeBSD. Signed-off-by: Gabriel Filion --- manifests/cron.pp | 1 + manifests/cron/freebsd.pp | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 manifests/cron/freebsd.pp diff --git a/manifests/cron.pp b/manifests/cron.pp index 693a430..9a632ff 100644 --- a/manifests/cron.pp +++ b/manifests/cron.pp @@ -5,6 +5,7 @@ class puppet::cron inherits puppet { linux: { include puppet::cron::linux } debian: { include puppet::cron::debian } openbsd: { include puppet::cron::openbsd } + freebsd: { include puppet::cron::freebsd } default: { include puppet::cron::base } } } diff --git a/manifests/cron/freebsd.pp b/manifests/cron/freebsd.pp new file mode 100644 index 0000000..5ff3419 --- /dev/null +++ b/manifests/cron/freebsd.pp @@ -0,0 +1,23 @@ +class puppet::cron::freebsd inherits puppet::freebsd { + + include puppet::cron::base + if $puppet_http_compression { $puppet_http_compression_str = '--http_compression' } + + if !$puppet_crontime { + $puppet_crontime_interval_minute = fqdn_rand(29) + $puppet_crontime_interval_minute2 = inline_template('<%= 30+puppet_crontime_interval_minute.to_i %>') + $puppet_crontime = "${puppet_crontime_interval_minute},${puppet_crontime_interval_minute2} * * * *" + } + + #TODO ensure that the service is disabled in /etc/rc.conf[.local] + + cron { 'puppetd_run': + command => "/usr/local/bin/puppet agent --onetime --no-daemonize --config=${puppet::puppet_config} --color false $puppet_http_compression_str | grep -E '(^err:|^alert:|^emerg:|^crit:)'", + user => 'root', + minute => split(regsubst($puppet_crontime,'^([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+)$','\1'),','), + hour => split(regsubst($puppet_crontime,'^([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+)$','\2'),','), + weekday => split(regsubst($puppet_crontime,'^([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+)$','\3'),','), + month => split(regsubst($puppet_crontime,'^([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+)$','\4'),','), + monthday => split(regsubst($puppet_crontime,'^([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+) ([\d,\-,*,/,\,]+)$','\5'),',') + } +} -- cgit v1.2.3 From f700886c55273330a01c38c20365d347b8c10d4a Mon Sep 17 00:00:00 2001 From: intrigeri Date: Sat, 15 Oct 2011 16:25:10 +0200 Subject: Fix lastruncheck. Patch by pietro. --- files/master/lastruncheck | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/files/master/lastruncheck b/files/master/lastruncheck index 149c655..d59e489 100644 --- a/files/master/lastruncheck +++ b/files/master/lastruncheck @@ -23,8 +23,8 @@ module Puppet::Lastcheck def facts_hosts return @facts_hosts if @facts_hosts require 'puppet/indirector/facts/yaml' - @facts_hosts = Puppet::Node::Facts.search("*").collect do |fqdn| - if node = Puppet::Node::Facts.find(fqdn) + @facts_hosts = Puppet::Node::Facts.indirection.search("*").collect do |fqdn| + if node = Puppet::Node::Facts.indirection.find(fqdn) { :hostname => node.name, :expired => node.expired?, :timestamp => node.values[:_timestamp], :expiration => node.expiration } end end.compact @@ -190,7 +190,7 @@ class Puppet::Application::Lastcheck < Puppet::Application exit(Puppet.settings.print_configs ? 0 : 1) if Puppet.settings.print_configs? #Puppet::Util::Log.newdestination :console - Puppet::Node::Facts.terminus_class = :yaml + Puppet::Node::Facts.indirection.terminus_class = :yaml Puppet::Lastcheck::Tests.tests.keys.each do |test| self.send("ignore_#{test}=", Puppet::Lastcheck::Tests.tests[test][:ignore_by_default]||false) unless self.send("ignore_#{test}") -- cgit v1.2.3 From 648e60b2ef63b42ff827618a3acb9bcef69d01f1 Mon Sep 17 00:00:00 2001 From: intrigeri Date: Sat, 17 Sep 2011 16:03:13 +0200 Subject: Revert "the debian-specific case doesn't work for squeeze, so re-factor the way it is" This reverts commit d38e7cf64902ff55138e5f85cc7c3b880ea5fb74. Current puppet package in Squeeze does not start by default => no need to special case it. --- manifests/cron/base.pp | 46 ++++++++++++++++++++++------------------------ 1 file changed, 22 insertions(+), 24 deletions(-) diff --git a/manifests/cron/base.pp b/manifests/cron/base.pp index 7b40da6..7daa6fb 100644 --- a/manifests/cron/base.pp +++ b/manifests/cron/base.pp @@ -1,34 +1,32 @@ # manifests/cron/base.pp class puppet::cron::base inherits puppet::base { - - case $operatingsystem { - debian: { if $lsbdistcodename != 'lenny' { $stop_service = true } else { $stop_service = false } } - openbsd, ubuntu: { $stop_service = false } - default: { $stop_service = true } - } - + Service['puppet']{ enable => false, } - if $stop_service == true { - $puppet_majorversion = regsubst($puppetversion,'^(\d+\.\d+).*$','\1') - if $puppet_majorversion == '2.6' { - Service['puppet']{ - ensure => stopped, - } - } else { - Service['puppet']{ - hasstatus => false, - pattern => 'puppetd', - } - # this works only on < 2.6 - exec { 'stop_puppet': - command => 'kill `cat /var/run/puppet/puppetd.pid`', - onlyif => 'test -f /var/run/puppet/puppetd.pid', - require => Service['puppet'], + case $operatingsystem { + debian,openbsd,ubuntu: { + #it's already disabled + } + default: { + $puppet_majorversion = regsubst($puppetversion,'^(\d+\.\d+).*$','\1') + if $puppet_majorversion == '2.6' { + Service['puppet']{ + ensure => stopped, + } + } else { + Service['puppet']{ + hasstatus => false, + pattern => 'puppetd', + } + # this works only on < 2.6 + exec { 'stop_puppet': + command => 'kill `cat /var/run/puppet/puppetd.pid`', + onlyif => 'test -f /var/run/puppet/puppetd.pid', + require => Service['puppet'], + } } } } } - -- cgit v1.2.3 From 506767d73515f79e05057df928bf7baa94b0dfcc Mon Sep 17 00:00:00 2001 From: Gabriel Filion Date: Sun, 8 Apr 2012 20:24:03 -0400 Subject: Fail when trying to ensure an installed version on FreeBSD The two package providers for FreeBSD are not able to ensure that a specific version of a package is installed because of how ports/pkg_add work. They can only ensure the version from the specified FreeBSD release is installed or absent. For more information, see: http://docs.puppetlabs.com/references/stable/type.html#features-4 To make the class easier to understand, let's not do something that users don't expect when they're requesting installation of a specific version. We'll explicitly fail and tell users why so that they can adjust how they use the class/module. Signed-off-by: Gabriel Filion --- manifests/freebsd.pp | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/manifests/freebsd.pp b/manifests/freebsd.pp index 3d0995d..cdce989 100644 --- a/manifests/freebsd.pp +++ b/manifests/freebsd.pp @@ -1,11 +1,20 @@ class puppet::freebsd inherits puppet::base { - if !$puppet_ensure_version { $puppet_ensure_version = 'installed' } + case $puppet_ensure_version { + '': { $puppet_ensure_version = 'installed' } + 'removed','absent','installed', 'present': {} # those values are OK + default: { fail('Package providers for FreeBSD cannot ensure that a specific version is installed.') } + } + case $facter_ensure_version { + '': { $facter_ensure_version = 'installed' } + 'removed','absent','installed', 'present': {} # those values are OK + default: { fail('Package providers for FreeBSD cannot ensure that a specific version is installed.') } + } + package { 'puppet': ensure => $puppet_ensure_version, } - if !$facter_ensure_version { $facter_ensure_version = 'installed' } package { 'facter': ensure => $facter_ensure_version, } -- cgit v1.2.3 From d60d201133b907b0d7afeb65787dd8dc444bf653 Mon Sep 17 00:00:00 2001 From: Micah Anderson Date: Wed, 11 Apr 2012 18:46:53 -0400 Subject: implement fix for cron file being put in place even when you do not include puppet::cron. The module should make sure that the cron file is not there if you aren't using the cron method, otherwise the daemon and the cronjob could both run. Used suggested change from jcharaoui in #3513 --- manifests/cron/linux.pp | 1 + manifests/linux.pp | 1 + 2 files changed, 2 insertions(+) diff --git a/manifests/cron/linux.pp b/manifests/cron/linux.pp index bab9564..5003559 100644 --- a/manifests/cron/linux.pp +++ b/manifests/cron/linux.pp @@ -16,5 +16,6 @@ class puppet::cron::linux inherits puppet::linux { source => undef, content => "#run puppet\n$puppet_crontime root output=\$(/usr/sbin/puppetd --onetime --no-daemonize --splay --config=/etc/puppet/puppet.conf --color false); ret=\$?; printf \"\\%s\" \"\$output\" | grep -E '(^err:|^alert:|^emerg:|^crit:)'; exit \$ret\n", before => Service['puppet'], + ensure => present } } diff --git a/manifests/linux.pp b/manifests/linux.pp index fcd3936..13788ef 100644 --- a/manifests/linux.pp +++ b/manifests/linux.pp @@ -19,5 +19,6 @@ class puppet::linux inherits puppet::base { "puppet:///modules/puppet/cron.d/puppetd.${operatingsystem}", "puppet:///modules/puppet/cron.d/puppetd" ], owner => root, group => 0, mode => 0644, + ensure => absent } } -- cgit v1.2.3 From 4ebf3b82818427303d4d9d83daca8addcbc6f53c Mon Sep 17 00:00:00 2001 From: intrigeri Date: Sat, 7 May 2011 20:37:08 +0200 Subject: Fix probable typos. --- manifests/puppetmaster.pp | 2 +- manifests/puppetmaster/base.pp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/manifests/puppetmaster.pp b/manifests/puppetmaster.pp index 4d1960d..3e8711c 100644 --- a/manifests/puppetmaster.pp +++ b/manifests/puppetmaster.pp @@ -24,7 +24,7 @@ class puppet::puppetmaster inherits puppet { } if $puppetmaster_mode == 'passenger' { - include puppet::puppetmaster::pasenger + include puppet::puppetmaster::passenger } elsif $puppetmaster_mode == 'cluster' { include puppet::puppetmaster::cluster } diff --git a/manifests/puppetmaster/base.pp b/manifests/puppetmaster/base.pp index 6ac1e0c..25709ea 100644 --- a/manifests/puppetmaster/base.pp +++ b/manifests/puppetmaster/base.pp @@ -20,7 +20,7 @@ class puppet::puppetmaster::base inherits puppet::base { if $puppetmaster_mode == 'passenger' { - include puppet::puppetmaster::pasenger + include puppet::puppetmaster::passenger File[$puppet_fileserverconfig]{ notify => Exec['notify_passenger_puppetmaster'], } -- cgit v1.2.3