File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change 81
81
$http_proxy_host = undef ,
82
82
$http_proxy_port = undef ,
83
83
$cron_hour = ' *' ,
84
- $cron_minute = ' */30 ' ,
84
+ $cron_minute = undef ,
85
85
) inherits puppet::params {
86
86
87
87
if ! defined (User[$::puppet::params::puppet_user ]) {
139
139
$service_ensure = ' stopped'
140
140
$service_enable = false
141
141
142
+ # Default to every 30 minutes - random around the clock
143
+ if $cron_minute == undef {
144
+ $time1 = fqdn_rand(30)
145
+ $time2 = $time1 + 30
146
+ $minute = [ $time1 , $time2 ]
147
+ }
148
+ else {
149
+ $minute = $cron_minute
150
+ }
151
+
142
152
cron { 'puppet-client' :
143
153
command => $puppet_run_command ,
144
154
user => ' root' ,
145
155
hour => $cron_hour ,
146
- minute => $cron_minute ,
156
+ minute => $minute ,
147
157
}
148
158
}
149
159
# Run Puppet through external tooling, like MCollective
You can’t perform that action at this time.
0 commit comments