summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--manifests/vhost/php/drupal.pp14
1 files changed, 10 insertions, 4 deletions
diff --git a/manifests/vhost/php/drupal.pp b/manifests/vhost/php/drupal.pp
index 537f912..06601f8 100644
--- a/manifests/vhost/php/drupal.pp
+++ b/manifests/vhost/php/drupal.pp
@@ -77,10 +77,16 @@ define apache::vhost::php::drupal(
}
if $manage_cron {
- file{"/etc/cron.d/drupal_cron_${name}":
- content => "0 * * * * apache wget -O - -q -t 1 http://${domain}/cron.php\n",
- owner => root, group => 0, mode => 0644;
- }
+ if $domain == 'absent' {
+ $real_domain = $name
+ } else {
+ $real_domain = $domain
+ }
+
+ file{"/etc/cron.d/drupal_cron_${name}":
+ content => "0 * * * * apache wget -O - -q -t 1 http://${real_domain}/cron.php\n",
+ owner => root, group => 0, mode => 0644;
+ }
}
# create vhost configuration file