Commit e831443c authored by Łukasz Nowak's avatar Łukasz Nowak Committed by Arnaud Fontaine

Make mysql server configurable.

parent 7e289d62
...@@ -986,7 +986,8 @@ class Recipe(BaseSlapRecipe): ...@@ -986,7 +986,8 @@ class Recipe(BaseSlapRecipe):
def installMysqlServer(self, ip, port, database='erp5', user='user', def installMysqlServer(self, ip, port, database='erp5', user='user',
test_database='test_erp5', test_user='test_user', template_filename=None, test_database='test_erp5', test_user='test_user', template_filename=None,
parallel_test_database_amount=100, mysql_conf=None): parallel_test_database_amount=100, mysql_conf=None, with_backup=True,
with_maatkit=True):
if mysql_conf is None: if mysql_conf is None:
mysql_conf = {} mysql_conf = {}
backup_directory = self.createBackupDirectory('mysql') backup_directory = self.createBackupDirectory('mysql')
...@@ -1060,6 +1061,7 @@ class Recipe(BaseSlapRecipe): ...@@ -1060,6 +1061,7 @@ class Recipe(BaseSlapRecipe):
)])) )]))
self.path_list.extend([mysql_conf_path]) self.path_list.extend([mysql_conf_path])
if with_backup:
# backup configuration # backup configuration
backup_directory = self.createBackupDirectory('mysql') backup_directory = self.createBackupDirectory('mysql')
full_backup = os.path.join(backup_directory, 'full') full_backup = os.path.join(backup_directory, 'full')
...@@ -1094,6 +1096,7 @@ class Recipe(BaseSlapRecipe): ...@@ -1094,6 +1096,7 @@ class Recipe(BaseSlapRecipe):
open(mysql_backup_cron, 'w').write('0 0 * * * ' + backup_controller) open(mysql_backup_cron, 'w').write('0 0 * * * ' + backup_controller)
self.path_list.append(mysql_backup_cron) self.path_list.append(mysql_backup_cron)
if with_maatkit:
# maatkit installation # maatkit installation
for mk_script_name in ( for mk_script_name in (
'mk-variable-advisor', 'mk-variable-advisor',
......
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