Backup MySQL databases before purging stack
This commit is contained in:
@@ -8,6 +8,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
|
||||
### v3.9.x - [Unreleased]
|
||||
|
||||
#### Added
|
||||
|
||||
- Sendmail stack to send WordPress welcome email properly
|
||||
- Backup all MySQL databases before removing/purging MySQL stack
|
||||
|
||||
#### Changed
|
||||
|
||||
- do not terminate stack install process on errors
|
||||
|
||||
@@ -692,6 +692,10 @@ class WOStackController(CementBaseController):
|
||||
if (set(["nginx-custom"]).issubset(set(apt_packages))):
|
||||
WOService.stop_service(self, 'nginx')
|
||||
|
||||
if (set(WOVariables.wo_mysql).issubset(set(apt_packages))):
|
||||
WOMysql.backupAll(self)
|
||||
WOService.stop_service(self, 'mysql')
|
||||
|
||||
# Netdata uninstaller
|
||||
if (set(['/var/lib/wo/tmp/'
|
||||
'kickstart.sh']).issubset(set(packages))):
|
||||
@@ -912,6 +916,10 @@ class WOStackController(CementBaseController):
|
||||
if (set(["fail2ban"]).issubset(set(apt_packages))):
|
||||
WOService.stop_service(self, 'fail2ban')
|
||||
|
||||
if (set(WOVariables.wo_mysql).issubset(set(apt_packages))):
|
||||
WOMysql.backupAll(self)
|
||||
WOService.stop_service(self, 'mysql')
|
||||
|
||||
# Netdata uninstaller
|
||||
if (set(['/var/lib/wo/tmp/'
|
||||
'kickstart.sh']).issubset(set(packages))):
|
||||
|
||||
Reference in New Issue
Block a user