-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL.txt
115 lines (87 loc) · 3.8 KB
/
INSTALL.txt
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
We assume the installation in the folder /srv/zinstances/urban414
(that can be changed) and on an ubuntu distribution.
Your real username must replace in our commands the string "username".
Each command, specified by the symbol ">", can be executed
(without the symbol >).
First we become root
> sudo -s
We install the necessary libraries
> apt-get install build-essential
> apt-get install libreadline5-dev
> apt-get install zlib1g-dev (support zlib)
> apt-get install libjpeg62-dev
> apt-get install subversion
> apt-get install libpq-dev
We work in the folder /srv
> cd /srv
We change the owner of the folder to avoid continue working as root
> chown -R username:username .
We leave the user root.
> exit
We create some directories
> mkdir install
> mkdir zinstances
> cd install
We install python2.6 that will be used to run the buildout and zope instance
> wget http://www.python.org/ftp/python/2.6.8/Python-2.6.8.tgz
> tar xvzf Python-2.6.8.tgz
> cd Python-2.6.8
> ./configure --prefix=/srv/python268
> make
> make install
We install the python utility easy_install
> cd /srv/install
> wget http://peak.telecommunity.com/dist/ez_setup.py
> /srv/python268/bin/python ez_setup.py
We install the python utility virtualenv
> /srv/python268/bin/easy_install virtualenv
We can define a cache for buildout
See http://www.communesplone.org/support/documentation/tutoriels/utilisation-dun-buildout/definition-dun-cache-pour-buildout/
We download the buildout files in our folder
> cd /srv/zinstances
> svn co http://svn.communesplone.org/svn/communesplone/buildout/server.urban/tags/make414/ urban414
> cd urban414
We modify the Makefile file to indicate the real path of the virtualenv utility.
To do that, you can edit the file in a simple text editor.
It's necessary to replace the line "virtualenv-2.6 --no-site-packages ." by
"/srv/python268/bin/virtualenv --no-site-packages ."
OR
You can create a link to our virtualenv without modifying Makefile
"sudo ln -s /srv/python268/bin/virtualenv /usr/local/bin/virtualenv-2.6"
we initialize the buildout
> make bootstrap
1) Installation without ZEO (one Zope instance)
We can modify in the file buildout.cfg the port (http-address) and the effective user
that will run the zope process.
We execute the buildout after each modification in the buildout.cfg file
> make buildout
OR
> bin/buildout -v
We start the zope server.
> bin/instance fg
OR
> bin/instance start
We can connect the zope server in a browser on the following address http://localhost:8080/manage_main
We can add a mount point (separate database file, defined in the file zope_add.conf)
=> choose in the list (up right in the browser page) "ZODB Mount Point"
Select a mount point name ("xxx" and click on "Create selected mount points").
All objects added in the zope folder "xxx" will be stored in the db file "xxx.fs"
in place of in "Data.fs".
2) Installation with ZEO (multiple Zope instances for the same database)
We can modify in the file buildout.cfg the port (http-address) and the effective user
that will run the zope process.
We can modify in the file zeo.cfg the port (zeo-address) of the zeo server.
We execute the buildout after each modification in the buildout.cfg file
> bin/buildout -v -c zeo.cfg
We start the zeo server.
> bin/zeoserver start
We start each zope server (following instance name section).
> bin/instance fg
OR
> bin/instance start
We can connect the zope server in a browser on the following address http://localhost:8080/manage_main
We can add a mount point (separate database file, defined in the file zeo_add.conf and zope_add_zeo.conf)
=> choose in the list (up right in the browser page) "ZODB Mount Point"
Select a mount point name ("xxx" and click on "Create selected mount points").
All objects added in the zope folder "xxx" will be stored in the db file "xxx.fs"
in place of in "Data.fs".