]> gitweb.fluxo.info Git - puppet-drupal.git/commitdiff
Adding action 'updatedb' into drupal script
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 5 Mar 2010 13:35:10 +0000 (10:35 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 5 Mar 2010 13:35:10 +0000 (10:35 -0300)
templates/drupal.sh.erb

index b966f93733d8f0a00def79a5669d198997471b18..26060fd47b67b85d3b34cbd1cf45e1865b1d8c3b 100644 (file)
@@ -40,6 +40,10 @@ function drupal_deploy {
 
 # Update all drupal instances in the host
 function drupal_update {
+  if [ -z "$update" ]; then
+    update="update"
+  fi
+
   for version in $SERIES; do
     # Setup base folder
     base="$BASE/drupal-$version"
@@ -57,7 +61,7 @@ function drupal_update {
       # Ignore symlinks so sites are updated just once
       if [ ! -h "$drupal" ] || [ ! -h "`readlink $drupal`" ]; then
         echo "Processing $drupal..."
-        drush -l $drupal update
+        drush -l $drupal $update
       fi
     done
   
@@ -154,6 +158,10 @@ elif [ "$1" == "deploy" ]; then
 elif [ "$1" == "update" ]; then
   shift
   drupal_update $*
+elif [ "$1" == "updatedb" ]; then
+  shift
+  update="updatedb"
+  drupal_update $*
 elif [ "$1" == "upgrade" ]; then
   shift
   drupal_upgrade $*