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
isaak yansane-sisk
slapos
Commits
8bac671a
Commit
8bac671a
authored
Jan 19, 2012
by
Antoine Catton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adapt lamp stack to p2p agents.
parent
0775766e
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
321 additions
and
130 deletions
+321
-130
stack/lamp/buildout.cfg
stack/lamp/buildout.cfg
+8
-6
stack/lamp/instance-apache-backup.cfg
stack/lamp/instance-apache-backup.cfg
+78
-3
stack/lamp/instance-backuped.cfg
stack/lamp/instance-backuped.cfg
+97
-67
stack/lamp/instance-mariadb-pbsready-export.cfg
stack/lamp/instance-mariadb-pbsready-export.cfg
+22
-11
stack/lamp/instance-mariadb-pbsready-import.cfg
stack/lamp/instance-mariadb-pbsready-import.cfg
+13
-9
stack/lamp/instance-mariadb-pbsready.cfg
stack/lamp/instance-mariadb-pbsready.cfg
+57
-18
stack/lamp/instance-pull-backup.cfg
stack/lamp/instance-pull-backup.cfg
+46
-16
No files found.
stack/lamp/buildout.cfg
View file @
8bac671a
...
...
@@ -51,6 +51,7 @@ extends =
../../component/mydumper/buildout.cfg
../../component/mysql-python/buildout.cfg
../../component/dropbear/buildout.cfg
../../component/gunicorn/buildout.cfg
versions = versions
...
...
@@ -90,14 +91,14 @@ mode = 0644
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-apache-backup.cfg
output = ${buildout:directory}/template-apache-backup.cfg
md5sum =
cfb77ac8785e0d125a785f69a5339014
md5sum =
2dca50fc8cd9548f8971d1675315d7ab
mode = 0644
[template-backuped]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-backuped.cfg
output = ${buildout:directory}/template-backuped.cfg
md5sum =
f43d1c6412ea8dc83b75573dc00daf9e
md5sum =
4ffb75f5c040cb0e1a1c02b89ee801a1
mode = 0644
[template-mariadb]
...
...
@@ -111,32 +112,33 @@ mode = 0644
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-mariadb-pbsready.cfg
output = ${buildout:directory}/template-mariadb-pbsready.cfg
md5sum =
d2a580dcd7efdd528be45c5ffadfe760
md5sum =
a55976b334cf2042b9182634a20fa25a
mode = 0644
[template-mariadb-pbsready-import]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-mariadb-pbsready-import.cfg
output = ${buildout:directory}/template-mariadb-pbsready-import.cfg
md5sum =
4a96ff02da3898fef7077fa8baec81ac
md5sum =
693745df17f339eadf8ada55ae0b88fb
mode = 0644
[template-mariadb-pbsready-export]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-mariadb-pbsready-export.cfg
output = ${buildout:directory}/template-mariadb-pbsready-export.cfg
md5sum =
11a9e45e8bc590bc11bfdd304b07a4a5
md5sum =
a3426f38c1e327a8d7d76d151e5d978d
mode = 0644
[template-pull-backup]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-pull-backup.cfg
output = ${buildout:directory}/template-pull-backup.cfg
md5sum = 9a
ab30ba5aa23a37d4b507e7c414be00
md5sum = 9a
f6bb88c876d3920da1c1c30cea171f
mode = 0644
[eggs]
recipe = zc.recipe.egg
eggs =
${gunicorn:eggs}
${lxml-python:egg}
slapos.toolbox
stack/lamp/instance-apache-backup.cfg
View file @
8bac671a
...
...
@@ -11,6 +11,11 @@ parts =
sshkeys-dropbear
dropbear-server
dropbear-server-pbs-authorized-key
request-pull-backup-server-apache-backup
agent
agent-wrapper
watchdog
logrotate-entry-equeue
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
...
...
@@ -19,8 +24,7 @@ offline = true
[urls]
recipe = slapos.cookbook:publish
url = http://[$${apache-proxy:ip}]:$${apache-proxy:port}/
ssh-public-key = $${sshkeys-dropbear:public-key-value}
ssh-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
agent-url = $${agent-data:url}
[apache-proxy]
recipe = slapos.cookbook:apacheproxy
...
...
@@ -127,6 +131,75 @@ name = logrotate
frequency = 0 0 * * *
command = $${logrotate:wrapper}
[request-pull-backup-server-apache-backup]
<= slap-connection
recipe = slapos.cookbook:request
name = Pull Backup Server pushing to backup Apache
software-url = $${slap-connection:software-release-url}
software-type = pull-backup
slave = true
config = url id type request-agent-url authorized-key
config-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
config-id = $${slap-parameter:pbs-id}
config-type = push
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
config-authorized-key = $${sshkeys-dropbear:public-key-value}
return = feed-url agent-url
[logrotate-entry-equeue]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = equeue
log = $${equeue:log}
frequency = daily
rotate-num = 30
[equeue]
recipe = slapos.cookbook:equeue
socket = $${basedirectory:run}/equeue.sock
log = $${basedirectory:log}/equeue.log
database = $${rootdirectory:srv}/equeue.db
wrapper = $${basedirectory:services}/equeue
equeue-binary = ${buildout:bin-directory}/equeue
[agent-data]
host = $${slap-network-information:global-ipv6}
port = 8081
url = http://[$${:host}]:$${:port}/
[agent]
<= agent-data
slap-connection
recipe = slapos.cookbook:agent
database = $${rootdirectory:srv}/agent.db
equeue-socket = $${equeue:socket}
callbacks-directory = $${directory:agent-callbacks}
wrapper = $${rootdirectory:bin}/agent
gunicorn = ${buildout:bin-directory}/gunicorn
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
config-file = $${rootdirectory:etc}/agent.py
peers =
$${slap-parameter:request-agent-url}
$${request-pull-backup-server-apache-backup:connection-agent-url}
[agent-wrapper]
recipe = slapos.cookbook:submanager
subcommand = $${agent:wrapper}
wrapper = $${basedirectory:services}/agent
pid-file = $${basedirectory:run}/agent.pid
binary = ${buildout:bin-directory}/submanager
config-files =
$${agent:config-file}
[watchdog]
recipe = slapos.cookbook:watchdog
agent-url = $${agent-data:url}
wrapper = $${basedirectory:services}/watchdog
binary = ${buildout:bin-directory}/wp-watchdog
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = $${buildout:directory}/etc/
...
...
@@ -142,6 +215,7 @@ services = $${rootdirectory:etc}/run/
run = $${rootdirectory:var}/run/
backup = $${rootdirectory:srv}/backup/
promises = $${rootdirectory:etc}/promise/
agent = $${rootdirectory:etc}/agent/
[directory]
recipe = slapos.cookbook:mkdirectory
...
...
@@ -152,5 +226,6 @@ cronstamps = $${rootdirectory:etc}/cronstamps/
cron-entries = $${rootdirectory:etc}/cron.d/
crontabs = $${rootdirectory:etc}/crontabs/
ssh = $${rootdirectory:etc}/ssh/
sshkeys = $${rootdirectory:srv}/sshkeys
sshkeys = $${rootdirectory:srv}/sshkeys
/
httpd-log = $${basedirectory:log}/apache/
agent-callbacks = $${basedirectory:agent}/callbacks/
stack/lamp/instance-backuped.cfg
View file @
8bac671a
...
...
@@ -8,10 +8,7 @@ parts =
request-mariadb-pseudo-replicating
request-apache-backup
request-pull-backup-server
request-pull-backup-server-mariadb
request-pull-backup-server-mariadb-backup
request-pull-backup-server-apache
request-pull-backup-server-apache-backup
url
apache-php
stunnel
...
...
@@ -25,6 +22,15 @@ parts =
dropbear-server
sshkeys-authority
dropbear-server-pbs-authorized-key
logrotate-entry-equeue
agent
agent-wrapper
watchdog
[uuid-generator]
recipe = slapos.cookbook:uuid
database = $${buildout:directory}/.uuid.db
uuids = mariadb-backup apache-backup
[sshkeys-directory]
recipe = slapos.cookbook:mkdirectory
...
...
@@ -70,21 +76,81 @@ path = $${directory:htdocs}
wrapper = $${rootdirectory:bin}/rdiffbackup-server
rdiffbackup-binary = ${buildout:bin-directory}/rdiff-backup
[agent-data]
host = $${slap-network-information:global-ipv6}
port = 8081
url = http://[$${:host}]:$${:port}/
[agent]
<= agent-data
slap-connection
recipe = slapos.cookbook:agent
database = $${rootdirectory:srv}/agent.db
equeue-socket = $${equeue:socket}
callbacks-directory = $${directory:agent-callbacks}
wrapper = $${rootdirectory:bin}/agent
gunicorn = ${buildout:bin-directory}/gunicorn
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
config-file = $${rootdirectory:etc}/agent.py
peers =
$${request-pull-backup-server:connection-agent-url}
$${request-mariadb:connection-agent-url}
$${request-mariadb-pseudo-replicating:connection-agent-url}
$${request-apache-backup:connection-agent-url}
[agent-wrapper]
recipe = slapos.cookbook:submanager
subcommand = $${agent:wrapper}
wrapper = $${basedirectory:services}/agent
pid-file = $${basedirectory:run}/agent.pid
binary = ${buildout:bin-directory}/submanager
config-files =
$${agent:config-file}
[watchdog]
recipe = slapos.cookbook:watchdog
agent-url = $${agent-data:url}
wrapper = $${basedirectory:services}/watchdog
binary = ${buildout:bin-directory}/wp-watchdog
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
[logrotate-entry-equeue]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = equeue
log = $${equeue:log}
frequency = daily
rotate-num = 30
[equeue]
recipe = slapos.cookbook:equeue
socket = $${basedirectory:run}/equeue.sock
log = $${basedirectory:log}/equeue.log
database = $${rootdirectory:srv}/equeue.db
wrapper = $${basedirectory:services}/equeue
equeue-binary = ${buildout:bin-directory}/equeue
[request-pull-backup-server]
<= slap-connection
recipe = slapos.cookbook:request
name = P
BS (Pull Backup Server)
name = P
ull Backup Server
software-url = $${slap-connection:software-release-url}
software-type = pull-backup
return = ssh-key notification-url feeds-url
config = request-agent-url
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
return = ssh-key agent-url
slave = false
[request-mariadb]
software-type = mariadb-pbsready-export
config = authorized-key
notify
config = authorized-key
pbs-id request-agent-url
config-authorized-key = $${request-pull-backup-server:connection-ssh-key}
config-notify = $${request-pull-backup-server:connection-notification-url}
return = url ssh-public-key ssh-url notification-id
config-pbs-id = $${uuid-generator:uuid-mariadb-backup}
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
return = url agent-url
[request-mariadb-pseudo-replicating]
<= slap-connection
...
...
@@ -92,11 +158,12 @@ recipe = slapos.cookbook:request
name = MariaDB Backup
software-url = $${slap-connection:software-release-url}
software-type = mariadb-pbsready-import
return = url ssh-public-key ssh-url notification-url
config = authorized-key on-notification
config = authorized-key pbs-id request-agent-url
config-authorized-key = $${request-pull-backup-server:connection-ssh-key}
pbs-notification-id = $${slap-connection:computer-id}-$${slap-connection:partition-id}-mariadb-push
config-on-notification = $${request-pull-backup-server:connection-feeds-url}$${:pbs-notification-id}
config-pbs-id = $${uuid-generator:uuid-mariadb-backup}
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
return = url agent-url
slave = false
[request-apache-backup]
<= slap-connection
...
...
@@ -104,71 +171,34 @@ recipe = slapos.cookbook:request
name = Apache Backup
software-url = $${slap-connection:software-release-url}
software-type = apache-backup
return = url
ssh-url ssh-public-key
config = authorized-key proxy-url
return = url
agent-url
config = authorized-key p
bs-id request-agent-url p
roxy-url
config-authorized-key = $${request-pull-backup-server:connection-ssh-key}
config-pbs-id = $${uuid-generator:uuid-apache-backup}
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
config-proxy-url = $${url:url}
return = url agent-url
[request-pull-backup-server-apache]
<= request-pull-backup-server
slap-connection
recipe = slapos.cookbook:request
name = PBS pulling from Apache
software-url = $${slap-connection:software-release-url}
config = url name type server-key notify notification-id frequency
config-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
config-name = $${slap-connection:computer-id}-$${slap-connection:partition-id}-apache
config-type = pull
config-server-key = $${sshkeys-dropbear:public-key-value}
config-notify = $${request-pull-backup-server:connection-notification-url}
config-notification-id = $${slap-connection:computer-id}-$${slap-connection:partition-id}-apache-pull
config-frequency = 30 * * * *
slave = true
[request-pull-backup-server-apache-backup]
<= request-pull-backup-server
slap-connection
<= slap-connection
recipe = slapos.cookbook:request
name = P
BS pushing to $${request-apache-backup:name}
name = P
ull Backup Server pulling from main Apache
software-url = $${slap-connection:software-release-url}
config = url name type server-key on-notification
config-url = $${request-apache-backup:connection-ssh-url}
config-name = $${request-pull-backup-server-apache:config-name}
config-type = push
config-server-key = $${request-apache-backup:connection-ssh-public-key}
config-on-notification = $${request-pull-backup-server:connection-feeds-url}$${request-pull-backup-server-apache:config-notification-id}
software-type = pull-backup
slave = true
[request-pull-backup-server-mariadb]
<= request-pull-backup-server
slap-connection
name = PBS pulling from $${request-mariadb:name}
config = url name type server-key on-notification notify notification-id title
config-url = $${request-mariadb:connection-ssh-url}
config-name = $${slap-connection:computer-id}-$${slap-connection:partition-id}-mariadb
config = url id type request-agent-url authorized-key frequency
config-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
config-id = $${uuid-generator:uuid-apache-backup}
config-type = pull
config-server-key = $${request-mariadb:connection-ssh-public-key}
config-on-notification = $${request-mariadb:connection-notification-id}
config-notify = $${request-pull-backup-server:connection-notification-url}
config-notification-id = $${slap-connection:computer-id}-$${slap-connection:partition-id}-mariadb-pull
config-title = Pulling from MariaDB
slave = true
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
config-authorized-key = $${sshkeys-dropbear:public-key-value}
config-frequency = 0 * * * *
return = feed-url agent-url
[request-pull-backup-server-mariadb-backup]
<= request-pull-backup-server
slap-connection
name = PBS pushing on $${request-mariadb-pseudo-replicating:name}
config = url name type server-key on-notification notify notification-id title
config-url = $${request-mariadb-pseudo-replicating:connection-ssh-url}
config-name = $${request-pull-backup-server-mariadb:config-name}
config-type = push
config-server-key = $${request-mariadb-pseudo-replicating:connection-ssh-public-key}
config-on-notification = $${request-pull-backup-server:connection-feeds-url}$${request-pull-backup-server-mariadb:config-notification-id}
config-notify = $${request-mariadb-pseudo-replicating:connection-notification-url}
config-notification-id = $${request-mariadb-pseudo-replicating:pbs-notification-id}
config-title = Pushing to MariaDB backup
slave = true
[basedirectory]
agent = $${rootdirectory:etc}/agent/
[directory]
ssh = $${rootdirectory:etc}/ssh/
sshkeys = $${rootdirectory:srv}/sshkeys
agent-callbacks = $${basedirectory:agent}/callbacks/
stack/lamp/instance-mariadb-pbsready-export.cfg
View file @
8bac671a
[buildout]
extends = ${template-mariadb-pbsready:output}
parts +=
cron-entry-mariadb-backup
[urls]
notification-id = http://[$${notifier:host}]:$${notifier:port}/get/$${notifier-mydumper:name}
parts +=
cron-entry-mariadb-backup
notifier-mydumper
mydumper
[mydumper]
recipe = slapos.cookbook:mydumper
wrapper = $${rootdirectory:bin}/
raw_mydumper
wrapper = $${rootdirectory:bin}/
mydumper_raw
backup-directory = $${directory:mariadb-backup}
socket = $${mariadb:socket}
user = root
mydumper-binary = ${mydumper:location}/bin/mydumper
database = $${mariadb:database}
import = false
compression = true
[notifier-mydumper-data]
write-url = $${urls:agent-url}log/mydumper
[notifier-mydumper]
<= notifier
recipe = slapos.cookbook:notifier.notify
name = mydumper
title = Dumping MariaDB Database
executable = $${mydumper:wrapper}
<= notifier-mydumper-data
recipe = slapos.cookbook:agent.notifier
wrapper = $${rootdirectory:bin}/mydumper
notify = $${slap-parameter:notify}
command-line = $${mydumper:wrapper}
notifier-binary = ${buildout:bin-directory}/wp-agent-notifier
title = Dumping MariaDB
notify-url =
$${request-pull-backup-server:connection-notify-url}
[cron-entry-mariadb-backup]
<= cron
...
...
@@ -31,3 +36,9 @@ recipe = slapos.cookbook:cron.d
name = backup
frequency = 0 * * * *
command = $${notifier-mydumper:wrapper}
[request-pull-backup-server]
name = Pull Backup Server pulling from main MariaDB
config-type = pull
config += trigger-feed
config-trigger-feed = $${notifier-mydumper-data:write-url}
stack/lamp/instance-mariadb-pbsready-import.cfg
View file @
8bac671a
[buildout]
extends = ${template-mariadb-pbsready:output}
parts += mariadb-import-on-notification
parts +=
trigger-mydumper-import
mydumper-import
[urls]
notification-url = http://[$${notifier:host}]:$${notifier:port}/notify
[trigger-mydumper-import]
<= agent
recipe = slapos.cookbook:agent.trigger
on-feed = $${request-pull-backup-server:connection-feed-url}
executable = $${mydumper-import:wrapper}
[mydumper-import]
recipe = slapos.cookbook:mydumper
...
...
@@ -17,8 +21,8 @@ myloader-binary = ${mydumper:location}/bin/myloader
database = $${mariadb:database}
import = true
[
mariadb-import-on-notification
]
<= notifier
recipe = slapos.cookbook:notifier.callback
on-notification-id = $${slap-parameter:on-notification}
c
allback = $${mydumper-import:wrapper
}
[
request-pull-backup-server
]
name = Pull Backup Server pushing on backup MariaDB
config-type = push
config += notify
c
onfig-notify = $${urls:notify-url
}
stack/lamp/instance-mariadb-pbsready.cfg
View file @
8bac671a
...
...
@@ -11,19 +11,20 @@ parts =
logrotate
logrotate-entry-mariadb
logrotate-entry-stunnel
logrotate-entry-cron
logrotate-entry-equeue
logrotate-entry-cron logrotate-entry-equeue
cron
cron-entry-logrotate
sshkeys-authority
dropbear-server
sshkeys-dropbear
dropbear-server-pbs-authorized-key
notifier
agent
agent-wrapper
watchdog
[urls]
ssh-public-key = $${sshkeys-dropbear:public-key-value}
ssh-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
agent-url = http://[$${agent:host}]:$${agent:port}/
notify-url = $${:agent-url}notify
[sshkeys-directory]
recipe = slapos.cookbook:mkdirectory
...
...
@@ -85,26 +86,64 @@ database = $${rootdirectory:srv}/equeue.db
wrapper = $${basedirectory:services}/equeue
equeue-binary = ${buildout:bin-directory}/equeue
[notifier]
recipe = slapos.cookbook:notifier
feeds = $${directory:notifier-feeds}
callbacks = $${directory:notifier-callbacks}
id-file = $${rootdirectory:etc}/notifier.id
equeue-socket = $${equeue:socket}
[agent-data]
host = $${slap-network-information:global-ipv6}
port = 8080
wrapper = $${basedirectory:services}/notifier
server-binary = ${buildout:bin-directory}/pubsubserver
notifier-binary = ${buildout:bin-directory}/pubsubnotifier
url = http://[$${:host}]:$${:port}/
[agent]
<= agent-data
slap-connection
recipe = slapos.cookbook:agent
database = $${rootdirectory:srv}/agent.db
equeue-socket = $${equeue:socket}
callbacks-directory = $${directory:agent-callbacks}
config-file = $${rootdirectory:etc}/agent.py
wrapper = $${rootdirectory:bin}/agent
gunicorn = ${buildout:bin-directory}/gunicorn
config-file = $${rootdirectory:etc}/agent.py
peers =
$${slap-parameter:request-agent-url}
$${request-pull-backup-server:connection-agent-url}
[agent-wrapper]
recipe = slapos.cookbook:submanager
subcommand = $${agent:wrapper}
wrapper = $${basedirectory:services}/agent
pid-file = $${basedirectory:run}/agent.pid
binary = ${buildout:bin-directory}/submanager
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
config-files =
$${agent:config-file}
[watchdog]
recipe = slapos.cookbook:watchdog
agent-url = $${agent-data:url}
wrapper = $${basedirectory:services}/watchdog
binary = ${buildout:bin-directory}/wp-watchdog
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
[request-pull-backup-server]
<= slap-connection
recipe = slapos.cookbook:request
software-url = $${slap-connection:software-release-url}
software-type = pull-backup
config = url id type authorized-key request-agent-url name
config-url = ssh://nobody@[$${dropbear-server:host}]:$${dropbear-server:port}/$${rdiff-backup-server:path}
config-id = $${slap-parameter:pbs-id}
config-authorized-key = $${sshkeys-dropbear:public-key-value}
config-request-agent-url = http://[$${agent-data:host}]:$${agent-data:port}/
config-name = $${:name}
return = feed-url agent-url notify-url
slave = true
[basedirectory]
cache = $${rootdirectory:var}/cache/
notifier = $${rootdirectory:etc}/notifier/
agent = $${rootdirectory:etc}/agent/
[directory]
mariadb-backup = $${basedirectory:backup}/mariadb/
ssh = $${rootdirectory:etc}/ssh/
sshkeys = $${rootdirectory:srv}/sshkeys
notifier-feeds = $${basedirectory:notifier}/feeds/
notifier-callbacks = $${basedirectory:notifier}/callbacks/
agent-callbacks = $${basedirectory:agent}/callbacks/
stack/lamp/instance-pull-backup.cfg
View file @
8bac671a
...
...
@@ -8,6 +8,9 @@ parts =
logrotate
sshkeys-authority
sshkeys-dropbear
agent
agent-wrapper
watchdog
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
...
...
@@ -16,8 +19,7 @@ offline = true
[connection-dict]
recipe = slapos.cookbook:publish
ssh-key = $${sshkeys-dropbear:public-key-value}
notification-url = http://[$${notifier:host}]:$${notifier:port}/notify
feeds-url = http://[$${notifier:host}]:$${notifier:port}/get/
agent-url = http://[$${agent:host}]:$${agent:port}/
[equeue]
recipe = slapos.cookbook:equeue
...
...
@@ -27,17 +29,43 @@ database = $${rootdirectory:srv}/equeue.db
wrapper = $${basedirectory:services}/equeue
equeue-binary = ${buildout:bin-directory}/equeue
[notifier]
recipe = slapos.cookbook:notifier
feeds = $${directory:notifier-feeds}
callbacks = $${directory:notifier-callbacks}
id-file = $${rootdirectory:etc}/notifier.id
equeue-socket = $${equeue:socket}
[agent-data]
host = $${slap-network-information:global-ipv6}
port = 8080
wrapper = $${basedirectory:services}/notifier
server-binary = ${buildout:bin-directory}/pubsubserver
notifier-binary = ${buildout:bin-directory}/pubsubnotifier
url = http://[$${:host}]:$${:port}/
[agent]
<= agent-data
slap-connection
recipe = slapos.cookbook:agent
database = $${rootdirectory:srv}/agent.db
equeue-socket = $${equeue:socket}
callbacks-directory = $${directory:agent-callbacks}
wrapper = $${rootdirectory:bin}/agent
gunicorn = ${buildout:bin-directory}/gunicorn
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
config-file = $${rootdirectory:etc}/agent.py
peers =
$${pbs:peers}
$${slap-parameter:request-agent-url}
[agent-wrapper]
recipe = slapos.cookbook:submanager
subcommand = $${agent:wrapper}
wrapper = $${basedirectory:services}/agent
pid-file = $${basedirectory:run}/agent.pid
binary = ${buildout:bin-directory}/submanager
config-files =
$${agent:config-file}
[watchdog]
recipe = slapos.cookbook:watchdog
agent-url = $${agent-data:url}
wrapper = $${basedirectory:services}/watchdog
binary = ${buildout:bin-directory}/wp-watchdog
partition-id = $${slap-connection:partition-id}
computer-id = $${slap-connection:computer-id}
[dropbear-client]
recipe = slapos.cookbook:dropbear.client
...
...
@@ -69,7 +97,6 @@ private-key = $${dropbear-client:identity-file}
wrapper = $${rootdirectory:bin}/do_backup
[pbs]
<= notifier
recipe = slapos.cookbook:pbs
client = true
rdiffbackup-binary = ${buildout:bin-directory}/rdiff-backup
...
...
@@ -79,8 +106,12 @@ promises-directory = $${basedirectory:promises}
directory = $${directory:pbs-backup}
cron-entries = $${cron:cron-entries}
wrappers-directory = $${directory:pbs-wrappers}
notifier-url = http://[$${notifier:host}]:$${notifier
:port}/
agent-url = http://[$${agent-data:host}]:$${agent-data
:port}/
slave-instance-list = $${slap-parameter:slave_instance_list}
runafter-binary = ${buildout:bin-directory}/runafter
notifier-binary = ${buildout:bin-directory}/wp-agent-notifier
wrapper-directory = $${directory:pbs-wrappers}
agent-callbacks-directory = $${directory:agent-callbacks}
[cron-simplelogger]
recipe = slapos.cookbook:simplelogger
...
...
@@ -161,12 +192,11 @@ logrotate-backup = $${basedirectory:backup}/logrotate/
sshkeys = $${rootdirectory:srv}/sshkeys
pbs-wrappers = $${rootdirectory:bin}/pbs/
dot-ssh = $${basedirectory:ssh-home}/.ssh/
notifier-feeds = $${basedirectory:notifier}/feeds/
notifier-callbacks = $${basedirectory:notifier}/callbacks/
agent-callbacks = $${basedirectory:agent}/callbacks/
[basedirectory]
ssh-home = $${rootdirectory:home}/ssh
notifier = $${rootdirectory:etc}/notifier
/
agent = $${rootdirectory:etc}/agent
/
[rootdirectory]
home = $${buildout:directory}/home/
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