Commit 82c1b54f authored by Łukasz Nowak's avatar Łukasz Nowak

- stabilise mysql instance profile

development.cfg:
 - define mysql_datadir for development profile
official.cfg:
 - globally define used mysql software component in official profile
mysql-tritonn-5.0-instance/buildout.cfg:
 - fix copy and paste issue with mysql_install_db
 - use profile configuration to access files produced by software component
 - made options less verbose

mysql-tritonn-5.0-instance/templates/mysqladmin.in:
mysql-tritonn-5.0-instance/templates/mysql.in:
 - use profile configuration to choose software component


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31902 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ef799508
[buildout]
extends = official.cfg
mysql_datadir = ${buildout:directory}/var/mysql
parts +=
mysql-instance
......
......@@ -33,15 +33,15 @@ output = ${buildout:directory}/bin/mysql
[mysql-admin]
recipe = collective.recipe.template
input = ${buildout:directory}/mysql-tritonn-5.0-instance/templates/mysqladmin.in
output = ${buildout:directory}/bin/mysqladmin[mysql_install_db]
output = ${buildout:directory}/bin/mysqladmin
[mysql_install_db]
recipe = plone.recipe.command
command =
${mysql-tritonn-5.0:location}/parts/bin/mysql_install_db --datadir=${mycnf:datadir}
${buildout:mysql_software}/bin/mysql_install_db --datadir=${mycnf:datadir}
echo
echo After starting supervisord, you may want to run:
echo ${buildout:directory}/parts/mysql/bin/mysqladmin -u root password 'new-password'
echo ${buildout:directory}/bin/mysqladmin -u root password 'new-password'
echo
update-command = ${mysql_install_db:command}
......@@ -49,14 +49,15 @@ update-command = ${mysql_install_db:command}
recipe = plone.recipe.command
command =
echo
echo These options are passed to mysqld_safe: ${mycnf:opt}
echo These options are passed to mysqld_safe: ${:opt}
echo
basedir=${mysql-tritonn-5.0:location}
datadir=${buildout:directory}/var
pid=${mycnf:datadir}/mysql.pid
err = ${mycnf:datadir}/log/mysql.err
sock = ${mycnf:datadir}/mysql.sock
opt = --port=${ports:mysql} --pid-file=${mycnf:pid} --log-error=${mycnf:err} --basedir=${mycnf:basedir} --datadir=${mycnf:datadir} --socket=${mycnf:sock}
basedir=${buildout:mysql_software}
datadir=${buildout:mysql_datadir}
# files shall be in better places
pid=${:datadir}/mysql.pid
err = ${buildout:directory}/mysql.err.log
sock = ${:datadir}/mysql.sock
opt = --port=${ports:mysql} --pid-file=${:pid} --log-error=${:err} --basedir=${:basedir} --datadir=${:datadir} --socket=${:sock}
[pidproxy]
# this should've been provided by collective.recipe.supervisor itself
......@@ -70,5 +71,5 @@ port = ${ports:supervisor}
serverurl = http://127.0.0.1:${ports:supervisor}
pp = ${buildout:directory}/eggs/supervisor-3.0a7-py2.5.egg/supervisor/pidproxy.py
programs =
10 mysql ${buildout:bin-directory}/pidproxy [ ${mycnf:pid} ${mysql-tritonn-5.0:location}/bin/mysqld_safe ${mycnf:opt} ]
10 mysql ${buildout:bin-directory}/pidproxy [ ${mycnf:pid} ${buildout:mysql_software}/bin/mysqld_safe ${mycnf:opt} ]
#!/bin/sh
${mysql-tritonn-5.0:location}/bin/mysql -P ${ports:mysql} -S ${mycnf:sock} -u root -p $*
${buildout:mysql_software}/bin/mysql -P ${ports:mysql} -S ${mycnf:sock} -u root -p $*
#!/bin/sh
${mysql-tritonn-5.0:location}/bin/mysqladmin -P ${ports:mysql} -S ${mycnf:sock} -u root -p $*
${buildout:mysql_software}/bin/mysqladmin -P ${ports:mysql} -S ${mycnf:sock} -u root -p $*
......@@ -27,3 +27,6 @@ parts =
openoffice
erp5-bt5
erp5-products
# XXX: shall be moved to mysql software buildout
mysql_software = ${mysql-tritonn-5.0:location}
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