Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
nexedi
/
slapos
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Merge Requests
39
Snippets
Network
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit 58fc57c5
authored
2017-05-22 16:22:25 +0900
by
Vincent Pelletier
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
stack.erp5: Factorise dash executable path generation in mariadb instance
1 parent
3ae90782
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
5 deletions
stack/erp5/buildout.hash.cfg
stack/erp5/instance-mariadb-resiliency-after-import-script.sh.in
stack/erp5/instance-mariadb.cfg.in
stack/erp5/buildout.hash.cfg
View file @
58fc57c
...
...
@@ -15,11 +15,11 @@
# not need these here).
[mariadb-resiliency-after-import-script]
filename = instance-mariadb-resiliency-after-import-script.sh.in
md5sum =
1e89de954d816b93f76d9b75820d192c
md5sum =
af0ef3e5e3ca0a2671e5eb65eb3faea6
[template-mariadb]
filename = instance-mariadb.cfg.in
md5sum =
e8c5a6669c0d3b6f05065146a7fc40f0
md5sum =
a99a56d0746303aecce5bbbcf2330dad
[template-kumofs]
filename = instance-kumofs.cfg.in
...
...
stack/erp5/instance-mariadb-resiliency-after-import-script.sh.in
View file @
58fc57c
#!${:dash}
#!${
dash
:dash}
# DO NOT RUN THIS SCRIPT ON PRODUCTION INSTANCE
# OR MYSQL DATA WILL BE ERASED.
...
...
stack/erp5/instance-mariadb.cfg.in
View file @
58fc57c
...
...
@@ -16,6 +16,7 @@
{% else -%}
{% set ip = (ipv4_set | list)[0] -%}
{% endif -%}
{% set dash = parameter_dict['dash-location'] ~ '/bin/dash' %}
[publish]
recipe = slapos.cookbook:publish.serialised
...
...
@@ -177,7 +178,7 @@ mysql_tzinfo_to_sql = ${binary-wrap-mysql_tzinfo_to_sql:wrapper-path}
# section is installed - so I only use jinja2 as a fancy way to write an
# executable file with partition-dependent but instance-parameters independent
# content.
template = inline:#!{{
parameter_dict['dash-location'] }}/bin/dash
template = inline:#!{{
dash }}
'{{ parameter_dict['mariadb-location'] }}/scripts/mysql_install_db' \
--defaults-file='${my-cnf:rendered}' \
--skip-name-resolve \
...
...
@@ -252,13 +253,15 @@ mode = 644
template = {{ 'inline:{{ "${directory:mariadb-data}/**\\n" }}' }}
rendered = ${directory:srv}/exporter.exclude
[dash]
dash = {{ dumps(dash) }}
[resiliency-after-import-script]
# Generate after import script used by importer instance of webrunner
recipe = collective.recipe.template
input = {{ parameter_dict['mariadb-resiliency-after-import-script'] }}
output = ${directory:srv}/runner-import-restore
mode = 755
dash = {{ parameter_dict['dash-location'] }}/bin/dash
[promise]
recipe = slapos.cookbook:wrapper
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment