From b371c43c3ea02d449d22f6cbc36ea48a06ae1e41 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Wed, 16 Dec 2015 09:41:03 -0200 Subject: Export PATH in drupal script --- files/drupal | 3 +++ manifests/init.pp | 4 ---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/files/drupal b/files/drupal index 948ed43..b2587fb 100755 --- a/files/drupal +++ b/files/drupal @@ -7,6 +7,9 @@ BASE=${BASE:="/var/www/data"} SITES=${SITES:="$BASE/drupal"} SERIES="5 6 7" +# Ensure we have a proper path, useful when called through cron +export PATH='/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' + # Read a parameter from user function drupal_user_input { local input diff --git a/manifests/init.pp b/manifests/init.pp index f250fe9..34a4fb1 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -39,7 +39,6 @@ class drupal( user => root, hour => "*/1", minute => "15", - path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin', ensure => present, require => File['/usr/local/sbin/drupal'], } @@ -52,7 +51,6 @@ class drupal( weekday => 5, hour => "02", minute => "30", - path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin', ensure => present, } @@ -63,7 +61,6 @@ class drupal( weekday => 4, hour => "02", minute => "30", - path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin', ensure => present, require => File['/usr/local/sbin/drupal', '/usr/local/share/drupal/drupal6.make', @@ -77,7 +74,6 @@ class drupal( weekday => 4, hour => "02", minute => "30", - path => '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin', ensure => present, require => File['/usr/local/sbin/drupal', '/usr/local/share/drupal/drupal7.make', -- cgit v1.2.3