From 37a0059803dc430752412930eb65e9a7f687d13b Mon Sep 17 00:00:00 2001 From: gau1991 Date: Fri, 6 Mar 2015 18:41:18 +0530 Subject: [PATCH 01/15] Fixed auth-sql-conf issue in mail --- ee/cli/plugins/stack.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ee/cli/plugins/stack.py b/ee/cli/plugins/stack.py index b694d3fb..7a319068 100644 --- a/ee/cli/plugins/stack.py +++ b/ee/cli/plugins/stack.py @@ -546,6 +546,14 @@ class EEStackController(CementBaseController): "/dovecot.pem") # Custom Dovecot configuration by EasyEngine + Log.debug(self, "Writting configuration into file" + "/etc/dovecot/conf.d/auth-sql.conf.ext ") + ee_dovecot = open('/etc/dovecot/conf.d/auth-sql.conf.ext', + encoding='utf-8', mode='w') + self.app.render((data), 'auth-sql-conf.mustache', + out=ee_dovecot) + ee_dovecot.close() + data = dict(email=EEVariables.ee_email) Log.debug(self, "Writting configuration into file" "/etc/dovecot/conf.d/99-ee.conf ") From 864c17cb869c294d0aeeb6082beac5a07b4948f2 Mon Sep 17 00:00:00 2001 From: gau1991 Date: Fri, 6 Mar 2015 19:21:11 +0530 Subject: [PATCH 02/15] Fixed data not available --- ee/cli/plugins/stack.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ee/cli/plugins/stack.py b/ee/cli/plugins/stack.py index 7a319068..b2bfb952 100644 --- a/ee/cli/plugins/stack.py +++ b/ee/cli/plugins/stack.py @@ -546,6 +546,7 @@ class EEStackController(CementBaseController): "/dovecot.pem") # Custom Dovecot configuration by EasyEngine + data = dict() Log.debug(self, "Writting configuration into file" "/etc/dovecot/conf.d/auth-sql.conf.ext ") ee_dovecot = open('/etc/dovecot/conf.d/auth-sql.conf.ext', From 6a79d452b7a3e2e63fbd1cdbbb30cd4e9b075e41 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Wed, 11 Mar 2015 17:43:53 +0530 Subject: [PATCH 03/15] moved custom handler to ext/ --- ee/cli/ext/ee_outputhandler.py | 19 +++++++++++++++++++ ee/cli/main.py | 24 ++++++++---------------- 2 files changed, 27 insertions(+), 16 deletions(-) create mode 100644 ee/cli/ext/ee_outputhandler.py diff --git a/ee/cli/ext/ee_outputhandler.py b/ee/cli/ext/ee_outputhandler.py new file mode 100644 index 00000000..32e1af8e --- /dev/null +++ b/ee/cli/ext/ee_outputhandler.py @@ -0,0 +1,19 @@ +# Based on https://github.com/datafolklabs/cement/issues/295 +# To avoid encoding releated error,we defined our custom output handler +# I hope we will remove this when we upgarde to Cement 2.6 (Not released yet) + +from cement.ext.ext_mustache import MustacheOutputHandler + + +class EEOutputHandler(MustacheOutputHandler): + class Meta: + label = 'ee_output_handler' + + def _load_template_from_file(self, path): + for templ_dir in self.app._meta.template_dirs: + full_path = fs.abspath(os.path.join(templ_dir, path)) + if os.path.exists(full_path): + self.app.log.debug('loading template file %s' % full_path) + return open(full_path, encoding='utf-8', mode='r').read() + else: + continue diff --git a/ee/cli/main.py b/ee/cli/main.py index ef828f51..9a89406f 100644 --- a/ee/cli/main.py +++ b/ee/cli/main.py @@ -14,9 +14,9 @@ from cement.core import foundation from cement.utils.misc import init_defaults from cement.core.exc import FrameworkError, CaughtSignal from cement.utils import fs -from cement.ext.ext_mustache import MustacheOutputHandler +from cement.ext.ext_argparse import ArgParseArgumentHandler from ee.core import exc - +from ee.cli.ext.ee_outputhandler import EEOutputHandler # Application default. Should update config/ee.conf to reflect any # changes, or additions here. @@ -31,22 +31,12 @@ defaults['ee']['plugin_dir'] = '/var/lib/ee/plugins' # External templates (generally, do not ship with application code) defaults['ee']['template_dir'] = '/var/lib/ee/templates' - -# Based on https://github.com/datafolklabs/cement/issues/295 -# To avoid encoding releated error,we defined our custom output handler -# I hope we will remove this when we upgarde to Cement 2.6 (Not released yet) -class EEOutputHandler(MustacheOutputHandler): +class EEArgHandler(ArgParseArgumentHandler): class Meta: - label = 'ee_output_handler' + label = 'ee_args_handler' - def _load_template_from_file(self, path): - for templ_dir in self.app._meta.template_dirs: - full_path = fs.abspath(os.path.join(templ_dir, path)) - if os.path.exists(full_path): - self.app.log.debug('loading template file %s' % full_path) - return open(full_path, encoding='utf-8', mode='r').read() - else: - continue + def error(self, message): + super(EEArgHandler, self).error("unknown args") class EEApp(foundation.CementApp): @@ -72,6 +62,8 @@ class EEApp(foundation.CementApp): # default output handler output_handler = EEOutputHandler + arg_handler = EEArgHandler + debug = TOGGLE_DEBUG From 8da13a161cb14176763cabbd328d081b19060406 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Wed, 11 Mar 2015 18:20:32 +0530 Subject: [PATCH 04/15] Error: global name 'fs' is not defined fixed --- ee/cli/ext/ee_outputhandler.py | 2 +- ee/cli/main.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/ee/cli/ext/ee_outputhandler.py b/ee/cli/ext/ee_outputhandler.py index 32e1af8e..ec4e906d 100644 --- a/ee/cli/ext/ee_outputhandler.py +++ b/ee/cli/ext/ee_outputhandler.py @@ -1,7 +1,7 @@ # Based on https://github.com/datafolklabs/cement/issues/295 # To avoid encoding releated error,we defined our custom output handler # I hope we will remove this when we upgarde to Cement 2.6 (Not released yet) - +from cement.utils import fs from cement.ext.ext_mustache import MustacheOutputHandler diff --git a/ee/cli/main.py b/ee/cli/main.py index 9a89406f..f3b89d88 100644 --- a/ee/cli/main.py +++ b/ee/cli/main.py @@ -13,7 +13,6 @@ else: from cement.core import foundation from cement.utils.misc import init_defaults from cement.core.exc import FrameworkError, CaughtSignal -from cement.utils import fs from cement.ext.ext_argparse import ArgParseArgumentHandler from ee.core import exc from ee.cli.ext.ee_outputhandler import EEOutputHandler From be3cd0540a00bde936671f55e787a51649fc03f1 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Wed, 11 Mar 2015 18:33:29 +0530 Subject: [PATCH 05/15] fixed global name 'os' is not defined --- ee/cli/ext/ee_outputhandler.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ee/cli/ext/ee_outputhandler.py b/ee/cli/ext/ee_outputhandler.py index ec4e906d..89e397d4 100644 --- a/ee/cli/ext/ee_outputhandler.py +++ b/ee/cli/ext/ee_outputhandler.py @@ -1,6 +1,7 @@ # Based on https://github.com/datafolklabs/cement/issues/295 # To avoid encoding releated error,we defined our custom output handler # I hope we will remove this when we upgarde to Cement 2.6 (Not released yet) +import os from cement.utils import fs from cement.ext.ext_mustache import MustacheOutputHandler From 64ddec56b44b9150775d3769664006b596316042 Mon Sep 17 00:00:00 2001 From: gau1991 Date: Wed, 11 Mar 2015 18:48:00 +0530 Subject: [PATCH 06/15] Changed apt-get function to Popen --- ee/core/aptget.py | 84 ++++++++++++++++++++++++++++++++--------------- 1 file changed, 58 insertions(+), 26 deletions(-) diff --git a/ee/core/aptget.py b/ee/core/aptget.py index fd64a7c9..be596a8f 100644 --- a/ee/core/aptget.py +++ b/ee/core/aptget.py @@ -2,6 +2,7 @@ import apt import apt_pkg import sys +import subprocess from ee.core.logging import Log from sh import apt_get from sh import ErrorReturnCode @@ -14,14 +15,24 @@ class EEAptGet(): """ Similar to `apt-get upgrade` """ - global apt_get - apt_get = apt_get.bake("-y") try: - for line in apt_get.update(_iter=True): - Log.info(self, Log.ENDC+line+Log.OKBLUE, end=' ') - except ErrorReturnCode as e: - Log.debug(self, "{0}".format(e)) - Log.error(self, "Unable to run apt-get update") + with open('/var/log/ee/ee.log', 'a') as f: + proc = subprocess.Popen('apt-get update {0}' + .format(all_packages), shell=True, + stdin=None, stdout=f, stderr=f, + executable="/bin/bash") + proc.wait() + + if proc.returncode == 0: + return True + else: + Log.debug(self, "Command Output: {0}, Command Error: {1}" + .format(cmd_stdout, cmd_stderr)) + + except Exception as e: + Log.error(self, "Error, while installing packages, " + "apt-get exited with status %s" + % e) def dist_upgrade(): """ @@ -44,30 +55,51 @@ class EEAptGet(): Log.error(self, 'Unable to Fetch update') def install(self, packages): - global apt_get - apt_get = apt_get.bake("-y") + all_packages = ' '.join(packages) try: - for line in apt_get.install("-o", - "Dpkg::Options::=--force-confold", - *packages, _iter=True): - Log.info(self, Log.ENDC+line+Log.OKBLUE, end=' ') - except ErrorReturnCode as e: - Log.debug(self, "{0}".format(e)) - Log.error(self, "Unable to run apt-get install") + with open('/var/log/ee/ee.log', 'a') as f: + proc = subprocess.Popen('apt-get install -y {0}' + .format(all_packages), shell=True, + stdin=None, stdout=f, stderr=f, + executable="/bin/bash") + proc.wait() + + if proc.returncode == 0: + return True + else: + Log.debug(self, "Command Output: {0}, Command Error: {1}" + .format(cmd_stdout, cmd_stderr)) + + except Exception as e: + Log.error(self, "Error, while installing packages, " + "apt-get exited with status %s" + % e) def remove(self, packages, auto=False, purge=False): - global apt_get - apt_get = apt_get.bake("-y") + all_packages = ' '.join(packages) try: - if purge: - for line in apt_get.purge(*packages, _iter=True): - Log.info(self, Log.ENDC+line+Log.OKBLUE, end=' ') + with open('/var/log/ee/ee.log', 'a') as f: + if purge: + proc = subprocess.Popen('apt-get purge -y {0}' + .format(all_packages), shell=True, + stdin=None, stdout=f, stderr=f, + executable="/bin/bash") + else: + proc = subprocess.Popen('apt-get remove -y {0}' + .format(all_packages), shell=True, + stdin=None, stdout=f, stderr=f, + executable="/bin/bash") + proc.wait() + if proc.returncode == 0: + return True else: - for line in apt_get.remove(*packages, _iter=True): - Log.info(self, Log.ENDC+line+Log.OKBLUE, end=' ') - except ErrorReturnCode as e: - Log.debug(self, "{0}".format(e)) - Log.error(self, "Unable to remove packages") + Log.debug(self, "Command Output: {0}, Command Error: {1}" + .format(cmd_stdout, cmd_stderr)) + + except Exception as e: + Log.error(self, "Error, while installing packages, " + "apt-get exited with status %s" + % e) def auto_clean(self): """ From e543c95c3c5db98a3bc2f54915117a134e06c4a9 Mon Sep 17 00:00:00 2001 From: gau1991 Date: Wed, 11 Mar 2015 19:02:10 +0530 Subject: [PATCH 07/15] Fixed global not defined --- ee/core/aptget.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ee/core/aptget.py b/ee/core/aptget.py index be596a8f..57c060f2 100644 --- a/ee/core/aptget.py +++ b/ee/core/aptget.py @@ -17,8 +17,8 @@ class EEAptGet(): """ try: with open('/var/log/ee/ee.log', 'a') as f: - proc = subprocess.Popen('apt-get update {0}' - .format(all_packages), shell=True, + proc = subprocess.Popen('apt-get update', + shell=True, stdin=None, stdout=f, stderr=f, executable="/bin/bash") proc.wait() From c8d2ef49ddbde0157f4879c2201e5b4e1faa7d6e Mon Sep 17 00:00:00 2001 From: gau1991 Date: Wed, 11 Mar 2015 19:16:30 +0530 Subject: [PATCH 08/15] Improved error message --- ee/core/aptget.py | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/ee/core/aptget.py b/ee/core/aptget.py index 57c060f2..12883fd3 100644 --- a/ee/core/aptget.py +++ b/ee/core/aptget.py @@ -26,13 +26,11 @@ class EEAptGet(): if proc.returncode == 0: return True else: - Log.debug(self, "Command Output: {0}, Command Error: {1}" - .format(cmd_stdout, cmd_stderr)) + Log.error(self, "Unable to run apt-get update") except Exception as e: - Log.error(self, "Error, while installing packages, " - "apt-get exited with status %s" - % e) + Log.error(self, "Error while installing packages, " + "apt-get exited with error") def dist_upgrade(): """ @@ -67,13 +65,11 @@ class EEAptGet(): if proc.returncode == 0: return True else: - Log.debug(self, "Command Output: {0}, Command Error: {1}" - .format(cmd_stdout, cmd_stderr)) + Log.error(self, "Unable to run apt-get install") except Exception as e: - Log.error(self, "Error, while installing packages, " - "apt-get exited with status %s" - % e) + Log.error(self, "Error while installing packages, " + "apt-get exited with error") def remove(self, packages, auto=False, purge=False): all_packages = ' '.join(packages) @@ -93,13 +89,11 @@ class EEAptGet(): if proc.returncode == 0: return True else: - Log.debug(self, "Command Output: {0}, Command Error: {1}" - .format(cmd_stdout, cmd_stderr)) + Log.error(self, "Unable to run apt-get remove/purge") except Exception as e: - Log.error(self, "Error, while installing packages, " - "apt-get exited with status %s" - % e) + Log.error(self, "Error while installing packages, " + "apt-get exited with error") def auto_clean(self): """ From 6d4b103dd4d1798391cd367ae04a2dbc897877e5 Mon Sep 17 00:00:00 2001 From: gau1991 Date: Mon, 16 Mar 2015 17:06:00 +0530 Subject: [PATCH 09/15] Added Dpkg::Options::=--force-confold to apt-get install --- ee/core/aptget.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ee/core/aptget.py b/ee/core/aptget.py index 12883fd3..5eff0cf7 100644 --- a/ee/core/aptget.py +++ b/ee/core/aptget.py @@ -56,7 +56,8 @@ class EEAptGet(): all_packages = ' '.join(packages) try: with open('/var/log/ee/ee.log', 'a') as f: - proc = subprocess.Popen('apt-get install -y {0}' + proc = subprocess.Popen("apt-get install -o Dpkg::Options::=--" + "force-confold -y {0}" .format(all_packages), shell=True, stdin=None, stdout=f, stderr=f, executable="/bin/bash") From 3f6d06042fba8d19b6e096242f1d6d22aa545ac0 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 13:34:33 +0530 Subject: [PATCH 10/15] updated ee debug usage --- ee/cli/plugins/debug.py | 29 +++++------------------------ 1 file changed, 5 insertions(+), 24 deletions(-) diff --git a/ee/cli/plugins/debug.py b/ee/cli/plugins/debug.py index 58c267b6..557f5f11 100644 --- a/ee/cli/plugins/debug.py +++ b/ee/cli/plugins/debug.py @@ -14,27 +14,6 @@ import glob import signal import subprocess -usage = """ -Usage: ee debug {} {arguments} - -arguments usage: ---all --all=on start debugging all server parameters. ---all=off stop debugging all server parameters ---nginx --nginx=on start debugging nginx server configuration for site ---nginx=off stop debugging nginx server configuration for site ---rewrite --rewrite=on start debugging nginx rewrite rules for site ---rewrite=off stop debugging nginx rewrite rules for site ---php --php=on start debugging server php configuration ---php=off stop debugging server php configuration ---fpm --fpm=on start debugging fastcgi configuration ---fpm=off stop debugging fastcgi configuration ---mysql --mysql=on start debugging mysql server ---mysql=off stop debugging mysql server ---wp --wp=on start wordpress debugging ---wp=off stop wordpress debugging - -""" - def debug_plugin_hook(app): # do something with the ``app`` object here. @@ -89,6 +68,7 @@ class EEDebugController(CementBaseController): (['site_name'], dict(help='Website Name', nargs='?', default=None)) ] + usage = "ee debug [] [options] " @expose(hide=True) def debug_nginx(self): @@ -493,9 +473,10 @@ class EEDebugController(CementBaseController): and (not self.app.pargs.all) and (not self.app.pargs.site_name)): if self.app.pargs.stop or self.app.pargs.start: - print("--start/stop option is deprecated in ee3.0.5", usage) + print("--start/stop option is deprecated in ee3.0.5") + self.app.args.print_help() else: - print(usage) + self.app.args.print_help() if self.app.pargs.all == 'on': if self.app.pargs.site_name: @@ -519,7 +500,7 @@ class EEDebugController(CementBaseController): and (not self.app.pargs.fpm) and (not self.app.pargs.mysql) and (not self.app.pargs.wp) and (not self.app.pargs.rewrite) and self.app.pargs.site_name): - print(usage) + self.app.args.print_help() # self.app.pargs.nginx = 'on' # self.app.pargs.wp = 'on' # self.app.pargs.rewrite = 'on' From c8cc0c9863d132cc32f15a4ef5b85455e8c74870 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 13:44:41 +0530 Subject: [PATCH 11/15] updated usage string --- ee/cli/plugins/clean.py | 1 + ee/cli/plugins/import_slow_log.py | 1 + ee/cli/plugins/info.py | 1 + ee/cli/plugins/log.py | 1 + ee/cli/plugins/secure.py | 1 + ee/cli/plugins/site.py | 1 + ee/cli/plugins/stack.py | 1 + 7 files changed, 7 insertions(+) diff --git a/ee/cli/plugins/clean.py b/ee/cli/plugins/clean.py index 28c5a5ab..b0f09e0d 100644 --- a/ee/cli/plugins/clean.py +++ b/ee/cli/plugins/clean.py @@ -31,6 +31,7 @@ class EECleanController(CementBaseController): (['--opcache'], dict(help='Clean OpCache', action='store_true')) ] + usage = "ee clean [options]" @expose(hide=True) def default(self): diff --git a/ee/cli/plugins/import_slow_log.py b/ee/cli/plugins/import_slow_log.py index b52bf72b..ba88fa08 100644 --- a/ee/cli/plugins/import_slow_log.py +++ b/ee/cli/plugins/import_slow_log.py @@ -16,6 +16,7 @@ class EEImportslowlogController(CementBaseController): stacked_on = 'base' stacked_type = 'nested' description = 'Import MySQL slow log to Anemometer database' + usage = "ee import-slow-log" @expose(hide=True) def default(self): diff --git a/ee/cli/plugins/info.py b/ee/cli/plugins/info.py index 4ec74db2..e2b00d28 100644 --- a/ee/cli/plugins/info.py +++ b/ee/cli/plugins/info.py @@ -33,6 +33,7 @@ class EEInfoController(CementBaseController): dict(help='Get Nginx configuration information', action='store_true')), ] + usage = "ee info [options]" @expose(hide=True) def info_nginx(self): diff --git a/ee/cli/plugins/log.py b/ee/cli/plugins/log.py index 6b5b3038..20274c4c 100644 --- a/ee/cli/plugins/log.py +++ b/ee/cli/plugins/log.py @@ -43,6 +43,7 @@ class EELogController(CementBaseController): (['site_name'], dict(help='Website Name', nargs='?', default=None)) ] + usage = "ee log [] [options]" @expose(hide=True) def default(self): diff --git a/ee/cli/plugins/secure.py b/ee/cli/plugins/secure.py index 09df15f2..3dddc9a7 100644 --- a/ee/cli/plugins/secure.py +++ b/ee/cli/plugins/secure.py @@ -34,6 +34,7 @@ class EESecureController(CementBaseController): dict(help='user input', nargs='?', default=None)), (['user_pass'], dict(help='user pass', nargs='?', default=None))] + usage = "ee secure [options]" @expose(hide=True) def default(self): diff --git a/ee/cli/plugins/site.py b/ee/cli/plugins/site.py index 8e86dfb6..cbf7e53b 100644 --- a/ee/cli/plugins/site.py +++ b/ee/cli/plugins/site.py @@ -31,6 +31,7 @@ class EESiteController(CementBaseController): (['site_name'], dict(help='Website name', nargs='?')), ] + usage = "ee site (command) [options]" @expose(hide=True) def default(self): diff --git a/ee/cli/plugins/stack.py b/ee/cli/plugins/stack.py index b2bfb952..96d34716 100644 --- a/ee/cli/plugins/stack.py +++ b/ee/cli/plugins/stack.py @@ -69,6 +69,7 @@ class EEStackController(CementBaseController): (['--utils'], dict(help='Install Utils stack', action='store_true')), ] + usage = "ee stack (command) [options]" @expose(hide=True) def default(self): From 5ebe2cdb4782317cb136f64d5ec22eda0cda5be7 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 18:26:26 +0530 Subject: [PATCH 12/15] wp core download failed issue handled --- ee/cli/plugins/site_functions.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ee/cli/plugins/site_functions.py b/ee/cli/plugins/site_functions.py index 5ab34e44..5b1aa88a 100644 --- a/ee/cli/plugins/site_functions.py +++ b/ee/cli/plugins/site_functions.py @@ -156,7 +156,8 @@ def setupwordpress(self, data): Log.info(self, "Downloading Wordpress \t\t", end='') EEFileUtils.chdir(self, '{0}/htdocs/'.format(ee_site_webroot)) - EEShellExec.cmd_exec(self, "wp --allow-root core download") + EEShellExec.cmd_exec(self, "wp --allow-root core download") or + Log.error("Unable to download wordpress core") Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]") if not (data['ee_db_name'] and data['ee_db_user'] and data['ee_db_pass']): From 80b8877072f7279f436827b03ec46cc90f26a552 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 18:33:37 +0530 Subject: [PATCH 13/15] fixed syntax --- ee/cli/plugins/site_functions.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ee/cli/plugins/site_functions.py b/ee/cli/plugins/site_functions.py index 5b1aa88a..5ecfc2cb 100644 --- a/ee/cli/plugins/site_functions.py +++ b/ee/cli/plugins/site_functions.py @@ -156,8 +156,9 @@ def setupwordpress(self, data): Log.info(self, "Downloading Wordpress \t\t", end='') EEFileUtils.chdir(self, '{0}/htdocs/'.format(ee_site_webroot)) - EEShellExec.cmd_exec(self, "wp --allow-root core download") or - Log.error("Unable to download wordpress core") + EEShellExec.cmd_exec(self, "wp --allow-root core" + "download") or Log.error("Unableto download wordpress" + " core") Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]") if not (data['ee_db_name'] and data['ee_db_user'] and data['ee_db_pass']): From ebc097540c762571f991d6a0357b98737e96ca52 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 18:45:44 +0530 Subject: [PATCH 14/15] fixed syntax --- ee/cli/plugins/site_functions.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ee/cli/plugins/site_functions.py b/ee/cli/plugins/site_functions.py index 5ecfc2cb..4ca013b9 100644 --- a/ee/cli/plugins/site_functions.py +++ b/ee/cli/plugins/site_functions.py @@ -157,8 +157,8 @@ def setupwordpress(self, data): Log.info(self, "Downloading Wordpress \t\t", end='') EEFileUtils.chdir(self, '{0}/htdocs/'.format(ee_site_webroot)) EEShellExec.cmd_exec(self, "wp --allow-root core" - "download") or Log.error("Unableto download wordpress" - " core") + "download") or Log.error(self, "Unableto download" + " wordpress core") Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]") if not (data['ee_db_name'] and data['ee_db_user'] and data['ee_db_pass']): From a0478724389ba84188d2c5d070379d83c91f8b65 Mon Sep 17 00:00:00 2001 From: harshadyeola Date: Tue, 17 Mar 2015 18:55:40 +0530 Subject: [PATCH 15/15] minor update --- ee/cli/plugins/site_functions.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ee/cli/plugins/site_functions.py b/ee/cli/plugins/site_functions.py index 4ca013b9..d7dcd6fe 100644 --- a/ee/cli/plugins/site_functions.py +++ b/ee/cli/plugins/site_functions.py @@ -157,8 +157,8 @@ def setupwordpress(self, data): Log.info(self, "Downloading Wordpress \t\t", end='') EEFileUtils.chdir(self, '{0}/htdocs/'.format(ee_site_webroot)) EEShellExec.cmd_exec(self, "wp --allow-root core" - "download") or Log.error(self, "Unableto download" - " wordpress core") + " download") or Log.error(self, "Unable to download" + " wordpress core") Log.info(self, "[" + Log.ENDC + "Done" + Log.OKBLUE + "]") if not (data['ee_db_name'] and data['ee_db_user'] and data['ee_db_pass']):