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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gabriel Monnerat
slapos
Commits
34da4fd7
Commit
34da4fd7
authored
Feb 26, 2013
by
Cédric de Saint Martin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cleanup and use of latest resilient improvements in lamp stack.
parent
b422a031
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
21 deletions
+21
-21
stack/lamp/apache/instance-apache-export.cfg.jinja2
stack/lamp/apache/instance-apache-export.cfg.jinja2
+12
-5
stack/lamp/apache/instance-apache-import.cfg.in
stack/lamp/apache/instance-apache-import.cfg.in
+1
-13
stack/lamp/buildout.cfg
stack/lamp/buildout.cfg
+3
-3
stack/lamp/mariadb/instance-mariadb-export.cfg.in
stack/lamp/mariadb/instance-mariadb-export.cfg.in
+5
-0
No files found.
stack/lamp/apache/instance-apache-export.cfg.jinja2
View file @
34da4fd7
# This file is responsible of t
wo
things:
# This file is responsible of t
hree
things:
# 1/ Act as "Apache exporter"
# 1/ Act as "Apache exporter"
# 2/ Act as "Mariadb backup infrastructure requester"
# 2/ Act as "Mariadb backup infrastructure requester"
# 3/ Act as "Apache" instance
{% import 'parts' as parts %}
{% import 'parts' as parts %}
{% import 'replicated' as replicated %}
{% import 'replicated' as replicated %}
...
@@ -9,7 +10,6 @@
...
@@ -9,7 +10,6 @@
extends = {{templateapache}}
extends = {{templateapache}}
{{templatepbsreadyexport}}
{{templatepbsreadyexport}}
parts +=
parts +=
{{ parts.replicate("mariadb", "3") }}
{{ parts.replicate("mariadb", "3") }}
...
@@ -34,17 +34,24 @@ parts +=
...
@@ -34,17 +34,24 @@ parts +=
# Nothing to do for the exporter. Just dummy part that does nothing.
# Nothing to do for the exporter. Just dummy part that does nothing.
# For httpd instance, PBS will directly pull data from srv/www.
# For httpd instance, PBS will directly pull data from srv/www.
# XXX-Cedric: write a real backup system.
[exporter]
[exporter]
wrapper = /bin/true
wrapper = /bin/true
# State that we want to backup srv/www directory, not srv/backup.
# State that we want to backup srv/www directory, not srv/backup.
# XXX-Cedric: works well, but doesn't work with big data.
[rdiff-backup-server]
[rdiff-backup-server]
path = ${directory:www}
path = ${directory:www}
# XXX-Cedric: resilient uses "urls" part to publish, but apache doesn't.
# Add "exporter" parameters to list of published connection parameters
[urls]
[publish-connection-informations]
<= publish-connection-informations
# XXX-Cedric: Long term goal: could be a recipe that requests an instance and
# bubbles ALL
# parameters of the requested instance. Requirement: aggregated publish.
<= resilient-publish-connection-parameter
# XXX-Cedric: resilient overwrites what's returned from request-mariadb
# XXX-Cedric: resilient overwrites what's returned from request-mariadb
# XXX-Cedric: change the request method to return everything from
# getConnectionParameterDict()
[request-mariadb]
[request-mariadb]
return = ssh-public-key ssh-url notification-id ip url
return = ssh-public-key ssh-url notification-id ip url
stack/lamp/apache/instance-apache-import.cfg.in
View file @
34da4fd7
...
@@ -3,30 +3,18 @@ eggs-directory = ${buildout:eggs-directory}
...
@@ -3,30 +3,18 @@ eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
offline = true
# XXX-Cedric: is instance-apache-php needed?
#extends = ${instance-apache-php:output}
# ${pbsready-import:output}
extends = ${pbsready-import:output}
extends = ${pbsready-import:output}
parts +=
# have to repeat the next one, as it's not inherited from pbsready-import
import-on-notification
[directory]
[directory]
srv = $${buildout:directory}/srv
srv = $${buildout:directory}/srv
www = $${:srv}/www/
www = $${:srv}/www/
# Nothing to do for the import. Just dummy part that does nothing.
# Nothing to do for the import. Just dummy part that does nothing.
# For httpd instance, PBS will directly push data to srv/www.
# For httpd instance, PBS will directly push data to srv/www.
# XXX-Cedric:
is it safe?
# XXX-Cedric:
write a real backup system.
[importer]
[importer]
wrapper = /bin/true
wrapper = /bin/true
# XXX-Cedric: resilient uses "urls" part to publish, but apache doesn't.
[urls]
recipe = slapos.cookbook:publish
# State that we want to push to srv/www directory, not srv/backup.
# State that we want to push to srv/www directory, not srv/backup.
[rdiff-backup-server]
[rdiff-backup-server]
path = $${directory:www}
path = $${directory:www}
stack/lamp/buildout.cfg
View file @
34da4fd7
...
@@ -81,7 +81,7 @@ mode = 0644
...
@@ -81,7 +81,7 @@ mode = 0644
recipe = slapos.recipe.template
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/apache/instance-apache-import.cfg.in
url = ${:_profile_base_location_}/apache/instance-apache-import.cfg.in
output = ${buildout:directory}/instance-apache-import.cfg
output = ${buildout:directory}/instance-apache-import.cfg
md5sum =
4067a0d32efbfad3923f3fe5a8ce77b4
md5sum =
f1dc2a71d362b5d2d36481ffefdd2293
mode = 0644
mode = 0644
[instance-apache-export]
[instance-apache-export]
...
@@ -95,7 +95,7 @@ context = key templateapache instance-apache-php:output
...
@@ -95,7 +95,7 @@ context = key templateapache instance-apache-php:output
import-list = file parts template-parts:destination
import-list = file parts template-parts:destination
file replicated template-replicated:destination
file replicated template-replicated:destination
md5sum =
6647004fd5a2a3d74e3d7f8aa6b4b226
md5sum =
2dc6134621b8a12817d43a979b84089a
mode = 0644
mode = 0644
[instance-resilient]
[instance-resilient]
...
@@ -131,7 +131,7 @@ mode = 0644
...
@@ -131,7 +131,7 @@ mode = 0644
recipe = slapos.recipe.template
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/mariadb/instance-mariadb-export.cfg.in
url = ${:_profile_base_location_}/mariadb/instance-mariadb-export.cfg.in
output = ${buildout:directory}/instance-mariadb-export.cfg
output = ${buildout:directory}/instance-mariadb-export.cfg
md5sum =
13703a15d9d73f59598505dac8ed4967
md5sum =
0352896921ca1766b64f0b54f0f8c27e
mode = 0644
mode = 0644
...
...
stack/lamp/mariadb/instance-mariadb-export.cfg.in
View file @
34da4fd7
...
@@ -18,6 +18,7 @@ parts +=
...
@@ -18,6 +18,7 @@ parts +=
slapmonitor
slapmonitor
slapmonitor-xml
slapmonitor-xml
# Define exporter strategy
[exporter]
[exporter]
recipe = slapos.cookbook:mydumper
recipe = slapos.cookbook:mydumper
wrapper = $${rootdirectory:bin}/$${slap-parameter:namebase}-exporter
wrapper = $${rootdirectory:bin}/$${slap-parameter:namebase}-exporter
...
@@ -27,3 +28,7 @@ user = root
...
@@ -27,3 +28,7 @@ user = root
mydumper-binary = ${mydumper:location}/bin/mydumper
mydumper-binary = ${mydumper:location}/bin/mydumper
database = $${mariadb:database}
database = $${mariadb:database}
import = false
import = false
# Extends publish section with resilient parameters
[urls]
<= resilient-publish-connection-parameter
\ No newline at end of file
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