site command improved
- argument empty error fixed - cache option install plugins with wrong permissions fixed
This commit is contained in:
parent
ce1f8d21a9
commit
14e19177af
|
@ -38,6 +38,8 @@ wp_cache_plugins() {
|
|||
else
|
||||
echo "${red}Redis Object Cache Plugin is already installed!${end}"
|
||||
fi
|
||||
|
||||
sudo chown -R www-data:www-data /var/www/$domain/htdocs/wp-content/plugins
|
||||
}
|
||||
|
||||
domain_check() {
|
||||
|
|
|
@ -124,7 +124,7 @@ if [[ "$domain" == "-list" && -z "$type" && -z "$cache" ]]; then
|
|||
for site in "/var/www"/*
|
||||
do
|
||||
domi=$(echo $site | cut -f 4 -d "/")
|
||||
echo "${gre} - $domi ${end}"
|
||||
[[ $domi != "html" && $domi != $(conf_read tools-port) ]] && echo "${gre} - $domi ${end}"
|
||||
done
|
||||
echo ""
|
||||
|
||||
|
@ -365,6 +365,7 @@ elif [[ "$type" == "-force-redirect" && -a /etc/nginx/sites-available/$domain ]]
|
|||
elif [[ ! -a /etc/nginx/sites-available/$domain && $type =~ ^(-nocache|-cache|-delete|-off|-on|-ssl-on|-ssl-off|-force-redirect)$ ]]; then
|
||||
echo "${red}Site $domain doesn't exists!${end}"
|
||||
else
|
||||
[[ -z $type ]] && type=$domain
|
||||
echo "${red} Argument '${type}' is not a valid option! ${end}"
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue