From a729e54425f56e639ed3fbce979f41c635927320 Mon Sep 17 00:00:00 2001 From: yumaojun <719118794@qq.com> Date: Sat, 27 Feb 2016 13:24:19 +0800 Subject: [PATCH] =?UTF-8?q?fix=20(install.py):=20=E3=80=80ubuntu=20=20auto?= =?UTF-8?q?=20install=20mysql-server?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1. auto install mysql server --- install/install.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/install/install.py b/install/install.py index 4f331d44a..82d7bcc7b 100755 --- a/install/install.py +++ b/install/install.py @@ -131,9 +131,9 @@ class PreSetup(object): self.db_host, self.db_pass)) if self._is_ubuntu: - cmd1 = 'echo mysql-server mysql-server/root_password select '' | debconf-set-selections' - cmd2 = 'echo mysql-server mysql-server/root_password_again select '' | debconf-set-selections' - cmd3 = 'apt-get -y install mysql-server' + cmd1 = "echo mysql-server mysql-server/root_password select '' | debconf-set-selections" + cmd2 = "echo mysql-server mysql-server/root_password_again select '' | debconf-set-selections" + cmd3 = "apt-get -y install mysql-server" bash('%s; %s; %s' % (cmd1, cmd2, cmd3)) bash('service mysql start') bash('mysql -e "create database %s default charset=utf8"' % self.db)