-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathINSTALL_singlehost.txt
More file actions
249 lines (169 loc) · 10 KB
/
INSTALL_singlehost.txt
File metadata and controls
249 lines (169 loc) · 10 KB
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
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
******************************************************
* SINGLE HOST INSTALLATION OF KOOL - THE CHURCH TOOL *
******************************************************
INTRODUCTION
============
As you have downloaded this package you seem to already know about kOOL - the church tool.
If not, just visit http://www.churchtool.org where you'll find a lot of information about kOOL.
This short guide is meant to get you started with kOOL.
This package is a single host installation that should only be used for tests or if you plan to only use one kOOL installation on your server.
Otherwise download the multi host package.
REQUIREMENTS
============
Webserver
---------
You will mainly need a webserver with Apache, PHP and MySQL or similar.
The main test sytem is Debian GNU/Linux. Everything should also run on a windows server.
Magic Quotes GPC
----------------
magic_quotes_gpc must be disabled in your php.ini in order for kOOL to work properly.
Smarty template enginge
-----------------------
The rendering of HTML in kOOL is done through the template engine smarty. On most linux systems smarty should be available as a ready-to-install package.
Make sure to include the path to smarty in your include_path directive in php.ini and to restart apache. (E.g. include_path = ".:/usr/share/php:/usr/share/php/smarty/libs") Or set the path in ko-config.php ($INCLUDE_PATH_SMARTY) if you can not change php.ini.
Find out more about smarty on http://www.smarty.net.
Mailserver
----------
If you want to use the email sending features of kOOL your server will need a working email server. Any mailserver should do as PHP's mail() function is beeing used to send emails from kOOL.
Emails are sent on different occasions: Manually to addresses stored in kOOL, moderation requests for events/reservations, rota plans, etc.
INSTALLATION STEP BY STEP
=========================
1. Get the kOOL single host package from http://www.churchtool.org
2. Unpack the zip file kOOL_<version>.zip and copy it to a folder in your webroot
# unzip kOOL_<version>.zip && mv kOOL_<version> /var/www/kOOL_demo
3. Make sure, the apache user (e.g. www-data) has write rights in this directory
# chown -R www-data /var/www/kOOL_demo
4. Make sure the apache user (e.g. www-data) has write access to these folders and their files:
cache, config, configs, download, my_images, templates_c webfolders, .webfolders
5. Create an empty database and a MySQL user with access to this database
6. Make your web directory accessible through your apache configuration and start the web based installation:
http://<your.kool.server>/install
UPDATE AN EXISTING KOOL INSTALLATION
====================================
1. Unpack the new kOOL package into a new folder
2. Manually copy all custom files from the current kOOL directory to the new one
These might be: ko.css, footer.php, header.php,
config/ko-config.php, config/kota.inc, config/leute_formular.inc,
my_images/*,
webfolders/, .webfolders/,
plugins/,
fpdf/
3. You may want to check for new settings in install/default/config/ko-config.php and merge them back into your ko-config.php
4. Update your kOOL database if necessary (check installation notes for this release on http://www.churchtool.org)
(5. Follow any additional instructions on http://www.churchtool.org for this release of kOOL)
OPTIONAL ADDITIONAL INSTALLATION STEPS
======================================
To get the maximum out of your kOOL you need to have access to an LDAP server and be able to install WebDAV on your webserver.
It is beyond the scope of this short installation instruction to give you the details about these technologies, but below you will find some hints
GD Library for PHP
------------------
To use the statistical charts in the people module you'll need the have the GD library for PHP installed on your webserver. This should usually ship with your distribution.
See http://www.php.net/manual/en/book.image.php for details.
LaTeX with KOMA scripts
-----------------------
The mailmerge feature is only available if LaTeX is installed with the KOMA scripts. kOOL tests for the executable 'pdflatex', so make sure this is available in your PATH. LaTeX with KOMA script should usually ship with your distribution, e.g. as texlive-latex-recommended in Debian.
For KOMA script see: http://www.komascript.de
Mailaccount for mailings
------------------------
In order to use the mailing module, you'll need an email domain with one single catch all account. Usually you would want to use your kOOL domain as an email account, e.g. kool.domain.tld. Just create one single email account (e.g. kOOL@kool.domain.tld) and configure it as a catch all account so alle emails to *@kool.domain.tld will arrive in this account. Fill out $MAILING_PARAMETER in your config/ko-config.php with the settings for this email catch all account.
Now you'll have to add a cronjob which runs the script mailing.php every few minutes, like so:
*/5 * * * * /usr/bin/php5 /var/www/kOOL_demo/mailing.php
For the mailing script to be able to access the POP3 account, your PHP must be configured with the imap extension. On Debian based systems a simple apt-get install php5-imap should be enough.
LDAP-Server
-----------
- Used schemas:
include /etc/ldap/schema/core.schema
include /etc/ldap/schema/cosine.schema
include /etc/ldap/schema/nis.schema
include /etc/ldap/schema/inetorgperson.schema
- Base structure for LDAP server:
-- demo.ldif ---------------------------------------------------------------
dn: ou=kOOL_demo,dc=your.ldap.server,dc=com
objectClass: top
objectClass: organizationalUnit
ou: kOOL_demo
dn: ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com
objectClass: top
objectClass: organizationalUnit
ou: login
dn: cn=kOOL_ldapadmin,ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com
objectClass: top
objectClass: person
sn: kOOL LDAP Admin
cn: kOOL_ldapadmin
userPassword: {SSHA}ENCODED_PASSWORD
-- demo.ldif ---------------------------------------------------------------
You can generate the encrypted password with the command
# slappassword
Substitute it in the above ldif file and import it into your LDAP directory:
# ldapadd -x -v -D cn=admin,dc=your.ldap.server,dc=com -W < demo.ldif
- You will need to grant the appropriate access rights to your LDAP directory in /etc/ldap/slapd.conf
(You might have to remove access lines from your default config file if present, as they might overwrite your settings below them.)
First for the kOOL_ldapadmin account, to be able to manage all the data:
-- slapd.conf --------------------------------------------------------------
access to attrs=userPassword
by dn="cn=kOOL_ldapadmin,ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com" write
by anonymous auth
by * none
-- slapd.conf --------------------------------------------------------------
Then you will have to activate authentication and read access to all kOOL users:
-- slapd.conf --------------------------------------------------------------
access to dn.subtree="ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com"
by dn="cn=kOOL_ldapadmin,ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com" write
by * auth
access to dn.subtree="ou=kOOL_demo,dc=your.ldap.server,dc=com"
by dn="cn=kOOL_ldapadmin,ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com" write
by dn.children="ou=login,ou=kOOL_demo,dc=your.ldap.server,dc=com" read
by * none
-- slapd.conf --------------------------------------------------------------
When your LDAP server is ready you can enable LDAP in kOOL. Add the following lines to your /path/to/kOOL/config/ko-config.php:
-- ko-config.php -----------------------------------------------------------
$ldap_enabled = TRUE;
$ldap_admin = "kOOL_ldapadmin";
$ldap_admin_pw = "PASSWORD";
$ldap_server = "your.ldap.server.com";
$ldap_dn = "ou=kOOL_demo,dc=your.ldap.server,dc=com";
-- ko-config.php -----------------------------------------------------------
WebDAV for webfolders
---------------------
You will need to have two apache modules installed:
- libapache-mod-dav
- libapache-mod-auth-mysql
The following setting for WebDAV can be done in the general setting of your webserver's configuration
-- httpd.conf -------------------------------------------------------------------------
<IfModule mod_dav.c>
DAVLockDB /var/lock/DAV/apache
</IfModule>
-- httpd.conf -------------------------------------------------------------------------
Then you have to add the following configuration for every kOOL installation. If you use virtual hosts, you can place this between <VirtualHost> and </VirtualHost>
This will turn on WebDAV for the given directory /path/to/kOOL/webfolders and set the settings for the authentication through the kOOL database. Of course you will have to add your values for the MySQL host, username, password and database.
-- httpd.conf -------------------------------------------------------------------------
<IfModule mod_dav.c>
<Directory "/path/to/kOOL/webfolders/">
AllowOverride AuthConfig FileInfo Limit Indexes
Options Indexes
ForceType text/plain
DAV On
AuthName "Webfolders kOOL"
AuthType Basic
AuthMySQL_Host localhost
AuthMySQL_User KOOL_MYSQL_USERNAME
AuthMySQL_Password KOOL_MYSQL_PASSWORD
Auth_MySQL_DB KOOL_MYSQL_DB
Auth_MySQL_Password_Table ko_admin
Auth_MySQL_Username_Field login
Auth_MySQL_Password_Field password
Auth_MySQL_Empty_Passwords Off
Auth_MySQL_Encryption_Types PHP_MD5
</Directory>
</IfModule>
-- httpd.conf -------------------------------------------------------------------------
Now make sure that webfolders are enabled in /path/to/kOOL/config/ko-config.php:
-- ko-config.php -----------------------------------------------------------
define("WEBFOLDERS", TRUE);
$WEBFOLDERS_BASE = $BASE_PATH."webfolders/";
$WEBFOLDERS_BASE_HTACCESS = $BASE_PATH.".webfolders/";
-- ko-config.php -----------------------------------------------------------
---------------------------------------
(c) Renzo Lauper <renzo@churchtool.org>
Last changes: 2010-12-30