wip for json schema
[slapos.git] / software / slapos-in-partition / common.cfg
1 [buildout]
2 extends =
3   ../../component/apache/buildout.cfg
4   ../../component/bash/buildout.cfg
5   ../../component/dcron/buildout.cfg
6   ../../component/dropbear/buildout.cfg
7   ../../component/gzip/buildout.cfg
8   ../../component/logrotate/buildout.cfg
9   ../../stack/slapos.cfg
10
11 parts =
12   instance-profile
13   slapos-cookbook
14   eggs
15
16 # Add hosting location of testing version of slapos.core
17 find-links +=
18   http://www.nexedi.org/static/packages/source/slapos.core-testing/
19
20 [environment]
21 recipe = collective.recipe.environment
22
23
24 [instance-profile]
25 # 3 advantages of using jinja2 for ALL templates:
26 # 1/ Explicit scope (pythonic style, we explicitely list what we want to be in the scope)
27 # 2/ No troubles between $ and $$ (more simple)
28 # 3/ We can explicitely define the path of executables (i.e
29 #    in software, define httpd-executable = ${apache:location}/bin/httpd
30 #    and in instance, just use httpd-executable without bother where it is actually
31 #    (location can change inside of the component, from bin to sbin for example).
32 recipe = slapos.recipe.template:jinja2
33 template = ${:_profile_base_location_}/instance.cfg.jinja2
34 rendered = ${buildout:directory}/instance.cfg
35 #md5sum = 4861be4a581686feef9f9edea865d7ee
36 mode = 0644
37 context =
38     key bin_directory buildout:bin-directory
39     key develop_eggs_directory buildout:develop-eggs-directory
40     key eggs_directory buildout:eggs-directory
41     key path environment:PATH
42     raw httpd_executable ${apache:location}/bin/httpd
43     raw bash_executable ${bash:location}/bin/bash
44     raw dcron_executable ${dcron:location}/sbin/crond
45     raw dropbear_executable ${dropbear:location}/sbin/dropbear
46     raw dropbearkey_executable ${dropbear:location}/bin/dropbearkey
47     raw gzip_executable ${gzip:location}/bin/gzip
48     raw gunzip_executable ${gzip:location}/bin/gunzip
49     raw logrotate_executable ${logrotate:location}/sbin/logrotate
50     raw slapos_configuration_file_template_path ${slapos-configuration-file-template:target}
51     raw httpd_configuration_file_template_path ${httpd-configuration-file-template:target}
52
53 [slapos-configuration-file-template]
54 # Download the template of slapos.cfg
55 recipe = slapos.recipe.download
56 url = ${:_profile_base_location_}/template/slapos.cfg.in
57 #md5sum = 
58 target = ${buildout:directory}/slapos.cfg.in
59 mode = 0644
60
61
62 [httpd-configuration-file-template]
63 # Download the template of httpd.conf
64 recipe = slapos.recipe.download
65 url = ${:_profile_base_location_}/template/httpd.conf.in
66 mode = 0644
67 #md5sum = 
68 #target = ${
69
70 [eggs]
71 recipe = zc.recipe.egg
72 eggs =
73   collective.recipe.template
74
75 # Add slapos.libnetworkcache to path of slapos.core.
76 [slapos-cookbook]
77 eggs =
78   ${lxml-python:egg}
79   slapos.cookbook
80   cliff
81   hexagonit.recipe.download
82   inotifyx
83   netaddr
84   netifaces
85   requests
86   slapos.core
87   supervisor
88   xml_marshaller
89   pytz
90   slapos.libnetworkcache
91