instance-apache-export.cfg.jinja2 1.89 KB
Newer Older
1
# This file is responsible of three things:
2 3
# 1/ Act as "Apache exporter"
# 2/ Act as "Mariadb backup infrastructure requester"
4
# 3/ Act as "Apache" instance
5 6 7 8 9 10 11 12 13 14

{% import 'parts' as parts %}
{% import 'replicated' as replicated %}

[buildout]
extends = {{templateapache}}
          {{templatepbsreadyexport}}

parts +=
    {{ parts.replicate("mariadb", "3") }}
15 16 17 18 19 20 21 22 23 24 25 26 27

# Repeating parts from instance-apache-php.
# XXX-Cedric: how to simplify this?
    certificate-authority
    ca-stunnel
    logrotate
    logrotate-entry-apache
    logrotate-entry-stunnel
    cron
    cron-entry-logrotate
    promise
    frontend-promise
    content-promise
28
    publish-connection-information
29 30 31

{{ replicated.replicate("mariadb", "3", "mariadb-export", "mariadb-import") }}

32 33 34 35 36 37 38
# Nothing to do for the exporter. This wrapper is intended
# to produce the "dump" files that have to be backed up.
# So, in case of binary DB data, we would back up the ASCII dump
# files, or a similar data format that can be restored on any machine
# (i.e. postgres 'custom')
# In the case of an httpd instance, the src/www directory can be directly
# pulled from the PBS, we don't need to prepare anything.
39
[exporter]
40
wrapper = /bin/true
41 42

# State that we want to backup srv/www directory, not srv/backup.
43
# XXX-Cedric: works well, but doesn't work with big data.
44 45 46
[rdiff-backup-server]
path = ${directory:www}

47
# Add "exporter" parameters to list of published connection parameters
48
[publish-connection-information]
49 50 51 52
# 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
53 54

# XXX-Cedric: resilient overwrites what's returned from request-mariadb
55 56
# XXX-Cedric: change the request method to return everything from
#             getConnectionParameterDict()
57 58
[request-mariadb]
return = ssh-public-key ssh-url notification-id ip url