forked from bananos/npp-buildout
-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildout-base.cfg
195 lines (154 loc) · 4.98 KB
/
buildout-base.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
[buildout]
# we're going to run everything under this user by default
user = bananos
group = staff
# Do not look for the newest packages, accept the minimal required version
newest = false
# We hate python eggs in zip
unzip = true
download-cache = ${buildout:directory}/thirdparty
#index = ${buildout:directory}/thirdparty
php-parts =
curl
jpeg
png
freetype
php
php-conf
php-fpm-conf
php-pecl
nginx-parts =
nginx
nginx-conf
# Default parts to compile
parts =
python
mkdirs
${buildout:nginx-parts}
${buildout:php-parts}
supervisor-conf
[python]
recipe = zc.recipe.egg
interpreter = python
eggs =
supervisor==3.0b2
[postgresql-conf]
recipe = collective.recipe.template
# Postgres base dir installed by brew
basedir = /usr/local/opt/postgresql/
datadir = ${buildout:directory}/var/pgdata
input = ${buildout:directory}/templates/postgresql.conf.in
output = ${buildout:directory}/etc/postgresql.conf
user = ${buildout:user}
group = ${buildout:group}
[curl]
recipe = hexagonit.recipe.cmmi
keep-compile-dir = false
url = http://curl.haxx.se/download/curl-7.30.0.tar.gz
configure-options =
--prefix=${buildout:directory}/parts/curl
[jpeg]
recipe = hexagonit.recipe.cmmi
keep-compile-dir = false
url = http://www.ijg.org/files/jpegsrc.v8d.tar.gz
configure-options =
--prefix=${buildout:directory}/parts/jpeg
[png]
recipe = hexagonit.recipe.cmmi
keep-compile-dir = false
url = http://prdownloads.sourceforge.net/libpng/libpng-1.5.10.tar.gz
configure-options =
--prefix=${buildout:directory}/parts/png
[freetype]
recipe = hexagonit.recipe.cmmi
keep-compile-dir = false
url = http://download.savannah.gnu.org/releases/freetype/freetype-2.4.0.tar.gz
configure-options =
--prefix=${buildout:directory}/parts/freetype
[php]
url = http://ua1.php.net/get/php-5.4.17.tar.gz/from/this/mirror
recipe = hexagonit.recipe.cmmi
keep-compile-dir = false
# MacOS-only use system libiconv
environment =
LIBS=/usr/lib/libiconv.dylib
configure-options =
--prefix=${buildout:directory}/parts/php
--enable-fpm
--enable-cli
--with-pgsql=${postgresql-conf:basedir}
--with-pdo-pgsql=${postgresql-conf:basedir}
--with-zlib
--with-bz2
--with-gd
--enable-gd-native-ttf
--with-openssl
--with-jpeg-dir=${buildout:directory}/parts/jpeg
--with-png-dir=${buildout:directory}/parts/png
--with-freetype-dir=${buildout:directory}/parts/freetype
--with-curl=${buildout:directory}/parts/curl
--with-gettext=/usr/local/opt/gettext/
--with-config-file-path=${buildout:directory}/etc/
--enable-ftp
--enable-mbstring
[php-pecl]
# Install various PHP binary extensions
recipe = iw.recipe.cmd
on_install = true
on_update = true
cmds =
# Install APC cache
printf "\n" | ${buildout:directory}/parts/php/bin/pecl install --force apc
# Install Oauth
printf "\n" | ${buildout:directory}/parts/php/bin/pecl install --force oauth
[pcre]
recipe = hexagonit.recipe.download
ignore-existing = true
url = http://ftp.cs.stanford.edu/mirrors/exim/pcre/pcre-8.33.tar.gz
strip-top-level-dir = true
[nginx]
recipe = hexagonit.recipe.cmmi
url = http://nginx.org/download/nginx-1.5.3.tar.gz
configure-options = --with-pcre=${pcre:destination} --with-http_ssl_module --with-http_gzip_static_module --with-http_stub_status_module
[supervisor-conf]
recipe = collective.recipe.template
input = ${buildout:directory}/templates/supervisord.conf.in
output = ${buildout:directory}/etc/supervisord.conf
[php-conf]
recipe = collective.recipe.template
input = ${buildout:directory}/templates/php.ini.in
output = ${buildout:directory}/etc/php.ini
[php-fpm-conf]
prefix =
recipe = collective.recipe.template
input = ${buildout:directory}/templates/php-fpm.conf.in
output = ${buildout:directory}/etc/php-fpm.conf
[nginx-conf]
hostname = mimvi.prod
webroot = ${buildout:directory}/var/www
recipe = collective.recipe.template
input = ${buildout:directory}/templates/nginx.conf.in
output = ${buildout:directory}/etc/nginx.conf
[mkdirs]
recipe = iw.recipe.cmd
on_install = true
on_update = true
cmds =
#Logs staff
mkdir -p ${buildout:directory}/var/log
#Sample phpinfo page
mkdir -p ${buildout:directory}/var/www
echo "<?php phpinfo();?>" > ${buildout:directory}/var/www/index.php
[postgresql-install-db]
recipe = plone.recipe.command
command =
mkdir -p ${postgresql-conf:datadir}
chmod 0700 ${postgresql-conf:datadir}
chown -R ${postgresql-conf:user}:${postgresql-conf:group} ${postgresql-conf:datadir}
${postgresql-conf:basedir}/bin/initdb ${postgresql-conf:datadir}
# override default config
mv ${buildout:directory}/etc/postgresql.conf ${postgresql-conf:datadir}/
mkdir -p ${buildout:directory}/var/log
mkdir -p ${buildout:directory}/var/www
rm -rf ${buildout:directory}/bin/psql
ln -s ${postgresql-conf:basedir}/bin/psql ${buildout:directory}/bin/psql