1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/movim_ynh.git synced 2024-09-03 19:46:19 +02:00

delete script php5-fpm pool & remove user after service

This commit is contained in:
src386 2015-08-27 07:37:28 +02:00
parent 2928a47059
commit 748d8567d0
4 changed files with 37 additions and 10 deletions

View file

@ -12,6 +12,8 @@ Current Movim version : 0.9 git2015-08-27
0.9b 2015-08-27
- Update to Movim 0.9 git2015-08-27
- Add notes in README about public pods & whitelisting
- Remove script now delete Movim php5-fpm pool.
- Remove script delete 'movim' user after shutting down Movim service.
0.8b 2015-08-24
- Added language selection : ar, de, es, it, ja, nl, ru

2
TODO
View file

@ -1,6 +1,4 @@
- Edit proxy_read_timeout and proxy_send_timeout values
- Check if path is not empty beforce install
- Add pid and syslog in movim.service (systemd)
- In remove script delete user after shuting down Movim service
- In remove script delete php5-fpm pool
- Set timezone in php5-fpm pool

25
q Normal file
View file

@ -0,0 +1,25 @@
#!/bin/bash
db_user=movim
db_name=movim
root_pwd=$(sudo cat /etc/yunohost/mysql)
#Stop service and remove init
sudo /etc/init.d/movim stop
sudo systemctl stop movim.service
sudo systemctl disable movim.service
sudo update-rc.d -f movim remove
sudo rm /etc/init.d/movim
sudo rm /lib/systemd/system/movim.service
#Drop database, movim files and user.
mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"
sudo userdel movim
sudo rm -rf /var/www/movim
domain=$(sudo yunohost app setting movim domain)
sudo rm -f /etc/nginx/conf.d/$domain.d/movim.conf
sudo rm -f /etc/nginx.
# Restarting services
sudo service nginx reload
sudo service php5-fpm restart

View file

@ -3,15 +3,8 @@
db_user=movim
db_name=movim
root_pwd=$(sudo cat /etc/yunohost/mysql)
mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"
# Removing executable files and user
sudo userdel movim
sudo rm -rf /var/www/movim
domain=$(sudo yunohost app setting movim domain)
sudo rm -f /etc/nginx/conf.d/$domain.d/movim.conf
#REMOVE INIT
#Stop service and remove init
sudo /etc/init.d/movim stop
sudo systemctl stop movim.service
sudo systemctl disable movim.service
@ -19,5 +12,14 @@ sudo update-rc.d -f movim remove
sudo rm /etc/init.d/movim
sudo rm /lib/systemd/system/movim.service
#Drop database, movim files and user.
mysql -u root -p$root_pwd -e "DROP DATABASE $db_name ; DROP USER $db_user@localhost ;"
sudo userdel movim
sudo rm -rf /var/www/movim
domain=$(sudo yunohost app setting movim domain)
sudo rm -f /etc/nginx/conf.d/$domain.d/movim.conf
udo rm etc/php5/fpm/pool.d/movim.conf
# Restarting services
sudo service nginx reload
sudo service php5-fpm restart