From 351d2a78cf9b67355ad6cf2da44f1b6325495cc5 Mon Sep 17 00:00:00 2001 From: Serghey Rodin Date: Tue, 2 Jan 2018 16:39:05 +0200 Subject: [PATCH] small fixes for softaculous plugin enable/disable --- bin/v-add-vesta-softaculous | 10 +++++++--- bin/v-delete-vesta-softaculous | 3 ++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/bin/v-add-vesta-softaculous b/bin/v-add-vesta-softaculous index be96196c..2eb31635 100755 --- a/bin/v-add-vesta-softaculous +++ b/bin/v-add-vesta-softaculous @@ -98,6 +98,8 @@ fi # Installing softaculous if [ ! -e "$VESTA/softaculous/vst_installed" ]; then + mkdir -p /var/softaculous + chown -R admin:admin /var/softaculous cd $VESTA/softaculous wget -q http://c.vestacp.com/3rdparty/softaculous_install.inc $VESTA/php/bin/php softaculous_install.inc @@ -105,9 +107,11 @@ if [ ! -e "$VESTA/softaculous/vst_installed" ]; then touch $VESTA/softaculous/vst_installed fi -# Adding symlink -if [ ! -e "$VESTA/web/softaculous" ]; then - ln -s $VESTA/softaculous/vesta $VESTA/web/softaculous +# Enabling symlink +if [ -e "$VESTA/disabled_plugins/softaculous" ]; then + if [ ! -e "$VESTA/web/softaculous" ]; then + mv $VESTA/disabled_plugins/softaculous $VESTA/web/softaculous + fi fi # Updating SOFTACULOUS value diff --git a/bin/v-delete-vesta-softaculous b/bin/v-delete-vesta-softaculous index cff7d2b8..c15d68c1 100755 --- a/bin/v-delete-vesta-softaculous +++ b/bin/v-delete-vesta-softaculous @@ -29,7 +29,8 @@ fi # Deleting symlink if [ -e "$VESTA/web/softaculous" ]; then - rm -f $VESTA/web/softaculous + mkdir -p $VESTA/disabled_plugins + mv $VESTA/web/softaculous $VESTA/disabled_plugins fi # Updating SOFTACULOUS value