Browse Source

Fix site cleanup on proxy and mysql site update

master
Prabuddha Chakraborty 9 years ago
parent
commit
6debbe9203
  1. 1
      ee/cli/plugins/site.py
  2. 4
      ee/cli/plugins/site_functions.py
  3. 7
      ee/cli/plugins/stack.py

1
ee/cli/plugins/site.py

@ -622,6 +622,7 @@ class EESiteCreateController(CementBaseController):
Log.info(self, Log.FAIL + "Oops Something went wrong !!")
Log.info(self, Log.FAIL + "Calling cleanup actions ...")
doCleanupAction(self, domain=ee_domain)
deleteSiteInfo(self, ee_domain)
Log.debug(self, str(e))
Log.error(self, "service nginx reload failed. "
"check issues with `nginx -t` command")

4
ee/cli/plugins/site_functions.py

@ -627,7 +627,7 @@ def sitebackup(self, data):
.format(data['site_name']), backup_path)
if data['currsitetype'] in ['html', 'php', 'proxy', 'mysql']:
if (data['pagespeed'] is True or data['old_pagespeed_status'] is True) and not data['wp']:
if (data['pagespeed'] is True or data['old_pagespeed_status'] is True or data['php7'] is True) and not data['wp']:
Log.info(self, "Backing up Webroot \t\t", end='')
EEFileUtils.copyfiles(self, ee_site_webroot + '/htdocs', backup_path + '/htdocs')
Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]")
@ -667,7 +667,7 @@ def sitebackup(self, data):
Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]")
# move wp-config.php/ee-config.php to backup
if data['currsitetype'] in ['mysql', 'proxy']:
if (data['pagespeed'] is True or data['old_pagespeed_status'] is True) and not data['wp']:
if (data['pagespeed'] is True or data['old_pagespeed_status'] is True or data['php7'] is True) and not data['wp']:
EEFileUtils.copyfile(self, configfiles[0], backup_path)
else:
EEFileUtils.mvfile(self, configfiles[0], backup_path)

7
ee/cli/plugins/stack.py

@ -1883,7 +1883,12 @@ class EEStackController(CementBaseController):
vm_config.close()
EEService.restart_service(self, 'dovecot')
EEService.reload_service(self, 'nginx')
EEService.reload_service(self, 'php5-fpm')
if EEVariables.ee_platform_codename != 'trusty':
EEService.reload_service(self, 'php5-fpm')
else:
EEService.reload_service(self, 'php5.6-fpm')
if EEAptGet.is_installed(self, 'php7.0-fpm'):
EEService.reload_service(self, 'php7.0-fpm')
self.msg = (self.msg + ["Configure ViMbAdmin:\thttps://{0}:"
"22222/vimbadmin".format(EEVariables.ee_fqdn)]
+ ["Security Salt: {0}".format(vm_salt)])

Loading…
Cancel
Save