libexec/unlock in alpha_omega-0.0.141 vs libexec/unlock in alpha_omega-0.0.142

- old
+ new

@@ -1,16 +1,23 @@ #!/bin/bash -e -hst_this=$(hostname -s) -if ! echo "$hst_this" | egrep -q "^(admin|develop)"; then - # unless the .ao_no_proxy file exists - if [[ ! -f ".ao_no_proxy" ]]; then - # ssh into deploy host and run from there - exec bin/proxy $(basename $0) "$@" - exit 1 - fi -fi +case "$(basename $0)" in + bump) + true + ;; + *) + hst_this=$(hostname -s) + if ! echo "$hst_this" | egrep -q "^(admin|develop)"; then + # unless the .ao_no_proxy file exists + if [[ ! -f ".ao_no_proxy" ]]; then + # ssh into deploy host and run from there + exec bin/proxy $(basename $0) "$@" + exit 1 + fi + fi + ;; +esac export LOCAL_ONLY=true default_pod=$(cat /etc/podname 2>&- || true) @@ -121,55 +128,51 @@ if [[ -n $1 ]]; then set $(for a in "$@"; do echo $a.app; done) fi case "$(basename $0)" in deploy) - bundle exec cap "$@" deploy + bundle exec cap "$@" deploy:lock deploy ;; release) - bundle exec cap "$@" deploy + bundle exec cap "$@" deploy:lock deploy ;; stage) - bundle exec cap "$@" deploy:update_code deploy:symlink_next + bundle exec cap "$@" deploy:lock deploy:update_code deploy:symlink_next ;; restart) - bundle exec cap "$@" deploy:restart + bundle exec cap "$@" deploy:lock deploy:restart ;; config) - bundle exec cap "$@" deploy:config + bundle exec cap "$@" deploy:lock deploy:config ;; build) - bundle exec cap "$@" deploy:build + bundle exec cap "$@" deploy:lock deploy:build ;; dist) - bundle exec cap "$@" deploy:dist + bundle exec cap "$@" deploy:lock deploy:dist ;; activate) - bundle exec cap "$@" deploy:symlink deploy:restart + bundle exec cap "$@" deploy:lock deploy:symlink deploy:restart ;; rollback) - bundle exec cap "$@" deploy:rollback + bundle exec cap "$@" deploy:lock deploy:rollback ;; check) - bundle exec cap "$@" deploy:check + bundle exec cap "$@" deploy:lock deploy:check ;; - compare) - bundle exec cap "$@" deploy:compare - ;; - plan) - bundle exec cap "$@" deploy:plan + bundle exec cap "$@" deploy:lock deploy:plan ;; lock) bundle exec cap "$@" deploy:dont_unlock deploy:lock ;; @@ -178,9 +181,17 @@ bundle exec cap "$@" deploy:unlock ;; shell) bundle exec cap "$@" shell + ;; + + compare) + bundle exec cap "$@" deploy:compare + ;; + + migrate) + bundle exec cap "$@" deploy:migrate ;; *) bundle exec cap "$@" ;;