From: Silvio Rhatto Date: Wed, 30 Dec 2009 16:32:45 +0000 (-0200) Subject: Minor fixes at template script X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=69dd03f5b9b8dbcc9fa707ee06634f79a919b59c;p=puppet-drupal.git Minor fixes at template script --- diff --git a/templates/drupal.sh.erb b/templates/drupal.sh.erb index 5b641c0..74a670a 100644 --- a/templates/drupal.sh.erb +++ b/templates/drupal.sh.erb @@ -45,7 +45,7 @@ function drupal_update { base="$BASE/drupal-$version" if [ ! -d "$base/sites" ]; then - break + continue fi # Setup site folders @@ -55,15 +55,19 @@ function drupal_update { # Issue updates for drupal in $drupals; do # Ignore symlinks so sites are updated just once - if [ ! -h $drupal ]; then + if [ ! -h "$drupal" ]; then echo "Processing $drupal..." drush -l $drupal update fi done # Fix permissions - chown -R root.root $base/sites/all/modules - chown -R root.root $base/sites/all/themes + if [ -e "$base/sites/all/modules" ]; then + chown -R root.root $base/sites/all/modules + fi + if [ -e "$base/sites/all/themes" ]; then + chown -R root.root $base/sites/all/themes + fi done }