From 6f6eb1b3542fa1ad1f3224d18066454cef37e5f5 Mon Sep 17 00:00:00 2001 From: Marcel Haerry Date: Mon, 11 May 2009 12:00:59 +0200 Subject: manage drupal crons --- manifests/defines/vhost_varieties.pp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/manifests/defines/vhost_varieties.pp b/manifests/defines/vhost_varieties.pp index 019147a..92295bb 100644 --- a/manifests/defines/vhost_varieties.pp +++ b/manifests/defines/vhost_varieties.pp @@ -462,6 +462,7 @@ define apache::vhost::php::drupal( $vhost_destination = 'absent', $htpasswd_file = 'absent', $htpasswd_path = 'absent', + $manage_cron = true ){ $documentroot = $path ? { 'absent' => $operatingsystem ? { @@ -471,6 +472,13 @@ define apache::vhost::php::drupal( default => "${path}/www" } + if $manage_cron { + file{"/etc/cron.d/drupal_cron_${name}": + content => "0 * * * * apache wget -O - -q -t 1 http://${doamin}/cron.php\n", + owner => root, group => 0, mode => 0644; + } + } + # create vhost configuration file apache::vhost::php::webapp{$name: ensure => $ensure, -- cgit v1.2.3