Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xavier Thompson
slapos
Commits
34362dba
Commit
34362dba
authored
Feb 26, 2021
by
Xavier Thompson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WIP theia resilient: WIP write export script
parent
e2793160
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
39 additions
and
4 deletions
+39
-4
software/theia/buildout.hash.cfg
software/theia/buildout.hash.cfg
+3
-3
software/theia/instance-theia-export.cfg.in
software/theia/instance-theia-export.cfg.in
+27
-1
software/theia/instance-theia-import.cfg.in
software/theia/instance-theia-import.cfg.in
+4
-0
software/theia/instance.cfg.in
software/theia/instance.cfg.in
+5
-0
No files found.
software/theia/buildout.hash.cfg
View file @
34362dba
...
...
@@ -15,7 +15,7 @@
[instance.cfg]
filename = instance.cfg.in
md5sum =
df9548360119b698568694a037ec9c76
md5sum =
65b944814af14846eeb71c125a2ac1cf
[instance-theia.cfg.jinja2.in]
filename = instance-theia.cfg.jinja2.in
...
...
@@ -23,11 +23,11 @@ md5sum = be9b217852da24d31ccc6d7c7a26a828
[instance-theia-import.cfg.in]
filename = instance-theia-import.cfg.in
md5sum =
56c5abad2384e82f83ae8f357d6bc4c
0
md5sum =
67b3b35208bbd7d5c66cd9e692189e9
0
[instance-theia-export.cfg.in]
filename = instance-theia-export.cfg.in
md5sum =
84639ad3d48b864e5ed1a5456b6a4754
md5sum =
e11eb44361e5aa2ffeaece27010aa1a7
[instance-theia-resilient.cfg.jinja2]
filename = instance-theia-resilient.cfg.jinja2
...
...
software/theia/instance-theia-export.cfg.in
View file @
34362dba
...
...
@@ -12,19 +12,45 @@ parts +=
$${:theia-environment-parts}
publish-connection-parameter
# The resilient stack makes the 'resilient' instance
# request the 'export' instance with a 'namebase' parameter.
# The export template then expects to receive it in
# slap-parameter:namebase
[slap-parameter]
namebase = ${slap-configuration:configuration.namebase}
# Change frontend name to help disambiguation
[apache-frontend]
name = Theia Export Frontend
# The resilient stack periodically calls exporter:wrapper
# and then notifies the pull-backup instance that data is ready
# to be pulled from the export instance.
[exporter]
recipe = slapos.cookbook:wrapper
command-line =
echo "hello"
command-line =
$${theia-exporter-args-script:rendered}
wrapper-path = $${directory:bin}/$${slap-parameter:namebase}-exporter
# wrapper parameter is needed by resilient stack
wrapper = $${:wrapper-path}
[transfer-args]
src = $${directory:srv}
dest = $${directory:backup}
include = $${directory:project}/src
exclude = *.1
[theia-exporter-args-script]
recipe = slapos.recipe.template:jinja2
rendered = $${directory:bin}/$${:_buildout_section_name_}
mode = 0700
template =
inline:#!${software-info:bash}
exec ${software-info:python} ${software-info:transfer} \
--src $${directory:srv} \
--dest $${directory:backup} \
--include $${directory:project}/src \
--exclude *.1
# Extends publish section with resilient parameters
[publish-connection-parameter]
<= resilient-publish-connection-parameter
software/theia/instance-theia-import.cfg.in
View file @
34362dba
...
...
@@ -20,6 +20,10 @@ namebase = ${slap-configuration:configuration.namebase}
[instance-parameter]
configuration.autorun = disabled
# Change frontend name to help disambiguation
[apache-frontend]
name = Theia Import Frontend
# The resilient stack calls importer:wrapper when the import instance
# is notified that the backup files have just been pushed to it.
[importer]
...
...
software/theia/instance.cfg.in
View file @
34362dba
...
...
@@ -29,6 +29,11 @@ pull-backup = template-pull-backup:rendered
theia-resilient = theia-resilient:rendered
RootSoftwareInstance = $${:default}
[software-info]
python = ${python:location}/bin/python
bash = ${bash:location}/bin/bash
transfer = ${transfer.py:output}
[template-base]
recipe = slapos.recipe.template
output = $${buildout:directory}/$${:filename}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment