#!/bin/bash domain=$(sudo yunohost app setting phpmyadmin domain) sudo rm -rf /var/www/phpmyadmin sudo rm -f /etc/nginx/conf.d/$domain.d/phpmyadmin.conf sudo rm -f /etc/php5/fpm/pool.d/phpmyadmin.conf sudo service php5-fpm restart sudo service nginx reload db_user=phpmyadmin db_name=phpmyadmin root_pwd=$(sudo cat /etc/yunohost/mysql) mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"