Provide executable shell
[slapos.git] / software / erp5 / snippet-master.cfg
1 #############################
2 #
3 # Instanciate zeo
4 #
5 # zeo-id -- local id of the requested zeo (1,2,3,...)
6 #
7 # zeo-port -- ip port to use to run the process
8 #
9 # storage_list -- string with list of all resquested storage
10 #    Example: event_module person_module
11 #
12 #############################
13 [buildout]
14 parts =
15   logrotate
16   cron
17   cron-entry-logrotate
18   certificate-authority
19   erp5-certificate-authority
20   tidstorage
21   cron-entry-tidstorage-backup
22   logrotate-entry-tidstorage
23   binary-link
24   erp5-update
25   %(part_list)s
26
27 eggs-directory = ${buildout:eggs-directory}
28 develop-eggs-directory = ${buildout:develop-eggs-directory}
29 offline = true
30
31 [tidstorage]
32 recipe = slapos.cookbook:tidstorage
33 known-tid-storage-identifier-dict = %(known_tid_storage_identifier_dict)s
34 base-url = http://$${%(haproxy_section)s:ip}:$${%(haproxy_section)s:port}/%%s/serialize
35 configuration-path = $${rootdirectory:etc}/tidstorage.py
36 ip = $${slap-network-information:local-ipv4}
37 port = 6001
38 timestamp-file-path = $${directory:tidstorage}/repozo_tidstorage_timestamp.log
39 logfile-name = $${basedirectory:log}/tidstorage.log
40 pidfile-name = $${basedirectory:run}/tidstorage.pid
41 status-file = $${directory:tidstorage}/tidstorage.tid
42 tidstorage-repozo-binary = ${buildout:bin-directory}/tidstorage_repozo
43 tidstoraged-binary = ${buildout:bin-directory}/tidstoraged
44 repozo-binary = ${buildout:bin-directory}/repozo
45 tidstorage-wrapper = $${basedirectory:services}/tidstoraged
46 repozo-wrapper = $${buildout:bin-directory}/tidstorage-repozo
47
48 [cron-entry-tidstorage-backup]
49 <= cron
50 recipe = slapos.cookbook:cron.d
51 name = tidstorage
52 frequency = 0 0 * * *
53 command = $${tidstorage:repozo-wrapper}
54
55 [logrotate-entry-tidstorage]
56 <= logrotate
57 recipe = slapos.cookbook:logrotate.d
58 name = tidstorage
59 log = $${tidstorage:logfile-name}
60 post = ${buildout:bin-directory}/killpidfromfile $${tidstorage:pidfile-name} SIGHUP
61
62 [directory]
63 recipe = slapos.cookbook:mkdirectory
64 cron-entries = $${rootdirectory:etc}/cron.d/
65 crontabs = $${rootdirectory:etc}/crontabs/
66 cronstamps = $${rootdirectory:etc}/cronstamps/
67 cronoutput = $${basedirectory:log}/cron/
68 logrotate-backup = $${basedirectory:backup}/logrotate/
69 logrotate-entries = $${rootdirectory:etc}/logrotate.d/
70
71 [cron]
72 recipe = slapos.cookbook:cron
73 dcrond-binary = ${dcron:location}/sbin/crond
74 cron-entries = $${directory:cron-entries}
75 crontabs = $${directory:crontabs}
76 cronstamps = $${directory:cronstamps}
77 catcher = $${cron-simplelogger:binary}
78 binary = $${basedirectory:services}/crond
79
80 [cron-simplelogger]
81 recipe = slapos.cookbook:simplelogger
82 binary = $${rootdirectory:bin}/cron_simplelogger
83 output = $${directory:cronoutput}
84
85 [cron-entry-logrotate]
86 <= cron
87 recipe = slapos.cookbook:cron.d
88 name = logrotate
89 frequency = 0 0 * * *
90 command = $${logrotate:wrapper}
91
92 # rest of parts are candidates for some generic stuff
93
94 [logrotate]
95 recipe = slapos.cookbook:logrotate
96 # Binaries
97 logrotate-binary = ${logrotate:location}/usr/sbin/logrotate
98 gzip-binary = ${gzip:location}/bin/gzip
99 gunzip-binary = ${gzip:location}/bin/gunzip
100 # Directories
101 wrapper = $${rootdirectory:bin}/logrotate
102 conf = $${rootdirectory:etc}/logrotate.conf
103 logrotate-entries = $${directory:logrotate-entries}
104 backup = $${directory:logrotate-backup}
105 state-file = $${rootdirectory:srv}/logrotate.status
106
107 [zeo-instance-entry-common]
108 recipe = slapos.cookbook:zeo
109 ip = $${slap-network-information:local-ipv4}
110 binary-path = ${buildout:bin-directory}/runzeo
111
112 [erp5-certificate-authority]
113 recipe = slapos.cookbook:certificate_authority
114 openssl-binary = ${openssl:location}/bin/openssl
115 ca-dir = $${directory:erp5-ca-dir}
116 requests-directory = $${erp5-cadirectory:requests}
117 wrapper = $${basedirectory:services}/erp5-ca
118 ca-private = $${erp5-cadirectory:private}
119 ca-certs = $${erp5-cadirectory:certs}
120 ca-newcerts = $${erp5-cadirectory:newcerts}
121 ca-crl = $${erp5-cadirectory:crl}
122
123 [erp5-cadirectory]
124 recipe = slapos.cookbook:mkdirectory
125 requests = $${directory:erp5-ca-dir}/requests/
126 private = $${directory:erp5-ca-dir}/private/
127 certs = $${directory:erp5-ca-dir}/certs/
128 newcerts = $${directory:erp5-ca-dir}/newcerts/
129 crl = $${directory:erp5-ca-dir}/crl/
130
131 [certificate-authority]
132 recipe = slapos.cookbook:certificate_authority
133 openssl-binary = ${openssl:location}/bin/openssl
134 ca-dir = $${directory:ca-dir}
135 requests-directory = $${cadirectory:requests}
136 wrapper = $${basedirectory:services}/ca
137 ca-private = $${cadirectory:private}
138 ca-certs = $${cadirectory:certs}
139 ca-newcerts = $${cadirectory:newcerts}
140 ca-crl = $${cadirectory:crl}
141
142 [cadirectory]
143 recipe = slapos.cookbook:mkdirectory
144 requests = $${directory:ca-dir}/requests/
145 private = $${directory:ca-dir}/private/
146 certs = $${directory:ca-dir}/certs/
147 newcerts = $${directory:ca-dir}/newcerts/
148 crl = $${directory:ca-dir}/crl/
149
150 [rootdirectory]
151 recipe = slapos.cookbook:mkdirectory
152 etc = $${buildout:directory}/etc/
153 var = $${buildout:directory}/var/
154 srv = $${buildout:directory}/srv/
155 bin = $${buildout:directory}/bin/
156 tmp = $${buildout:directory}/tmp/
157
158 [basedirectory]
159 recipe = slapos.cookbook:mkdirectory
160 log = $${rootdirectory:var}/log/
161 services = $${rootdirectory:etc}/run/
162 run = $${rootdirectory:var}/run/
163 backup = $${rootdirectory:srv}/backup/
164
165 [directory]
166 recipe = slapos.cookbook:mkdirectory
167 tidstorage = $${rootdirectory:srv}/tidstorage/
168 zodb = $${rootdirectory:srv}/zodb/
169 zodb-backup = $${basedirectory:backup}/zodb
170 instance = $${rootdirectory:srv}/erp5shared/
171 instance-etc = $${:instance}/etc
172 apache-conf = $${rootdirectory:etc}/apache
173 instance-etc-package-include = $${:instance}/etc/package-include
174 # because of bug in slapos.recipe.template keys are lowercased
175 instance-document = $${:instance}/Document
176 instance-propertysheet = $${:instance}/PropertySheet
177 instance-products = $${:instance}/Products
178 instance-extensions = $${:instance}/Extensions
179 instance-constraint = $${:instance}/Constraint
180 instance-import = $${:instance}/import
181 instance-lib = $${:instance}/lib
182 instance-tests = $${:instance}/tests
183 erp5-ca-dir = $${rootdirectory:srv}/erp5-ssl/
184 ca-dir = $${rootdirectory:srv}/ssl/
185 cron-entries = $${rootdirectory:etc}/cron.d/
186 crontabs = $${rootdirectory:etc}/crontabs/
187 cronstamps = $${rootdirectory:etc}/cronstamps/
188 cronoutput = $${basedirectory:log}/cron/
189 logrotate-backup = $${basedirectory:backup}/logrotate/
190 logrotate-entries = $${rootdirectory:etc}/logrotate.d/
191
192 [binary-link]
193 recipe = slapos.cookbook:symbolic.link
194 target-directory = $${rootdirectory:bin}
195 link-binary = 
196   ${coreutils:location}/bin/basename
197   ${coreutils:location}/bin/cat
198   ${coreutils:location}/bin/cp
199   ${coreutils:location}/bin/ls
200   ${coreutils:location}/bin/tr
201   ${coreutils:location}/bin/uname
202   ${git:location}/bin/git
203   ${graphviz:location}/bin/dot
204   ${grep:location}/bin/grep
205   ${imagemagick:location}/bin/convert
206   ${imagemagick:location}/bin/identify
207   ${mariadb:location}/bin/mysql
208   ${mariadb:location}/bin/mysqldump
209   ${pdftk:location}/bin/pdftk
210   ${sed:location}/bin/sed
211   ${tesseract:location}/bin/tesseract
212   ${w3m:location}/bin/w3m
213   ${poppler:location}/bin/pdfinfo
214   ${poppler:location}/bin/pdftotext
215   ${poppler:location}/bin/pdftohtml
216
217 [erp5-update]
218 recipe = slapos.cookbook:erp5.update
219
220 # Configuration
221 url = http://$${%(zope_section)s:user}:$${%(zope_section)s:password}@$${%(zope_section)s:ip}:$${%(zope_section)s:port}/
222 mysql-url = %(mysql-url)s
223 kumofs-url = %(kumofs-url)s
224 memcached-url = %(memcached-url)s
225 cloudooo-url = %(cloudooo-url)s
226 site-id = %(site_id)s
227 openssl-binary = ${openssl:location}/bin/openssl
228 cadir-path = $${erp5-certificate-authority:ca-dir}
229
230 # Paths
231 update-wrapper = $${basedirectory:services}/erp5-update
232
233 # Defaults
234 configurator-bt5-list = erp5_full_text_myisam_catalog erp5_configurator_standard erp5_configurator_maxma_demo erp5_configurator_ung erp5_configurator_ung erp5_configurator_run_my_doc
235 bt5-repository-list = $${%(zope_section)s:bt5-repository-list}