Commit 93804130 authored by Romain Courteaud's avatar Romain Courteaud

End script if database is created.

parent da0db1f5
...@@ -40,8 +40,7 @@ def updateMysql(args): ...@@ -40,8 +40,7 @@ def updateMysql(args):
conf = args[0] conf = args[0]
sleep = 30 sleep = 30
is_succeed = False is_succeed = False
while True: while not is_succeed:
if not is_succeed:
mysql_upgrade_list = [conf['mysql_upgrade_binary'], '--no-defaults', '--user=root', '--socket=%s' % conf['socket']] mysql_upgrade_list = [conf['mysql_upgrade_binary'], '--no-defaults', '--user=root', '--socket=%s' % conf['socket']]
mysql_upgrade = subprocess.Popen(mysql_upgrade_list, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) mysql_upgrade = subprocess.Popen(mysql_upgrade_list, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
result = mysql_upgrade.communicate()[0] result = mysql_upgrade.communicate()[0]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment