add snippet 'get-cloud-instance-to-update'..

This commit is contained in:
2023-08-02 14:23:46 +02:00
parent f244232347
commit 08a9bc984d
17 changed files with 103 additions and 685 deletions

View File

@ -214,37 +214,13 @@ clear
echo ""
echo -e "\033[32m-----\033[m"
echo "Create missing indices"
echo "Replace favicon icon"
echo -e "\033[32m-----\033[m"
WEBSITE=
_OK=false
echo ""
echo "Which site would you like to update?"
echo ""
declare -i i=0
for _site in ${website_arr[@]} ; do
IFS=':' read -a _arr <<< ${_site}
echo " [$i] ${_arr[0]}"
((i++))
done
echo
echononl " Eingabe: "
while ! $_OK ; do
read _IN
if is_number "$_IN" && [[ -n ${website_arr[$_IN]} ]]; then
IFS=':' read -a _arr <<< ${website_arr[$_IN]}
conf_file=${_arr[1]}
DEFAULT_WEBSITE="${_arr[0]}"
_OK=true
else
echo ""
echo -e "\tFalsche Eingabe !"
echo ""
echononl " Eingabe: "
fi
done
# Which cloud instance (website) would you like to update
#
source ${snippet_dir}/get-cloud-instance-to-update
# - Reset IFS
@ -278,10 +254,6 @@ DEFAULT_HTTP_GROUP="www-data"
DEFAULT_PHP_ENGINE="FPM"
if [[ -z ${WEBSITE} ]] ; then
WEBSITE="$DEFAULT_WEBSITE"
fi
DEFAULT_WEB_BASE_DIR="/var/www/$WEBSITE"
[[ -n "$WEB_BASE_DIR" ]] || WEB_BASE_DIR=$DEFAULT_WEB_BASE_DIR