zoph: wordpress: Various fixes for issues brought by shared daemon
After shared daemon implementation, when apps are disabled, mariadb is no longer guaranteed to be running. This means operations such as install, backup, restore, re-run, uninstall fail trying to do database operations. Fix this and various small related issues.