diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2011-07-28 16:58:43 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2011-07-28 16:58:43 -0300 |
commit | a9f08a2e6e7593e5398daf5bb6b66e29a97426c7 (patch) | |
tree | 0083a94a4442dc3e829fe5882e664bc32d8bed8d /templates/drupal.sh.erb | |
parent | 8b17d2a64976aaeba2f5d1597d1581a28ab13c6a (diff) | |
download | puppet-drupal-a9f08a2e6e7593e5398daf5bb6b66e29a97426c7.tar.gz puppet-drupal-a9f08a2e6e7593e5398daf5bb6b66e29a97426c7.tar.bz2 |
Adding video-scheduler drupal action
Diffstat (limited to 'templates/drupal.sh.erb')
-rw-r--r-- | templates/drupal.sh.erb | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/templates/drupal.sh.erb b/templates/drupal.sh.erb index 2665571..afc3ed1 100644 --- a/templates/drupal.sh.erb +++ b/templates/drupal.sh.erb @@ -188,9 +188,27 @@ function drupal_make { fi } +# Run the video scheduler +function drupal_video_scheduler { + if [ -z "$2" ]; then + echo "Usage: `basename $0` video-scheduler <site> <series>" + exit 1 + fi + + site="$1" + version="$2" + drupal_folder="$BASE/drupal-$version" + scheduler="$drupal_folder/sites/all/modules/video/video_scheduler.php" + site_folder="$drupal_folder/sites/$site" + + if [ -f "$scheduler" ] && [ -e "$site" ]; then + php $scheduler -r $drupal_folder -s $site + fi +} + # Main procedure if [ -z "$1" ]; then - echo "Usage: `basename $0` <cron|deploy|update|updatedb|upgrade|run|make> [arguments]" + echo "Usage: `basename $0` <cron|deploy|update|updatedb|upgrade|run|make|video-scheduler> [arguments]" exit 1 elif [ "$1" == "cron" ]; then drupal_iterate cron @@ -216,6 +234,9 @@ elif [ "$1" == "run" ]; then elif [ "$1" == "make" ]; then shift drupal_make $* +elif [ "$1" == "video-scheduler" ]; then + shift + drupal_video_scheduler $* else echo "No action $1" exit 1 |