dev-scripts/scripts/reset-wordpress.sh

16 lines
320 B
Bash
Executable File

echo "Removing WordPress .."
_mysql_cmd="mysql -uroot -p$db_root_pass -e "
ssh -T $ssh << EOSSH
# remove database
if command -v mysql ; then
$_mysql_cmd "DROP DATABASE $wp_db_name;"
else
echo "ERROR: no installed database found - aborting WordPress removal"
exit 40
fi
# remove files
rm -Rf $wp_path
EOSSH