diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2011-12-19 15:37:43 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2011-12-19 15:37:43 -0200 |
commit | 34ce4a513dc9f6db315bbe71f6a66230abb0273e (patch) | |
tree | 612d904e59ef5edf61c7857db61381017a3b77af | |
parent | 70704ff97fa8e6fea87cd9ab463af98c2db671e0 (diff) | |
download | puppet-wordpress-34ce4a513dc9f6db315bbe71f6a66230abb0273e.tar.gz puppet-wordpress-34ce4a513dc9f6db315bbe71f6a66230abb0273e.tar.bz2 |
Check for previous installation
-rw-r--r-- | templates/wordpress.sh.erb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/templates/wordpress.sh.erb b/templates/wordpress.sh.erb index 33d473c..60a15e9 100644 --- a/templates/wordpress.sh.erb +++ b/templates/wordpress.sh.erb @@ -61,6 +61,12 @@ function wordpress_upgrade { wordpress_check_existing $new cd $BASE + + if [ ! -d "wordpress-$old" ]; then + echo "Installation not found: wordpress-$old" + exit + fi + cp -a wordpress-$old wordpress-$old.backup # Deploy a fresh wordpress tree |