View | Details | Raw Unified | Return to bug 9316
Collapse All | Expand All

(-)a/C4/Installer/PerlDependencies.pm (+20 lines)
Lines 284-289 our $PERL_DEPS = { Link Here
284
        'required' => '1',
284
        'required' => '1',
285
        'min_ver'  => '3.15'
285
        'min_ver'  => '3.15'
286
    },
286
    },
287
    'Starman' => {
288
	'usage' => 'preforking PSGI/PLACK web server',
289
	'required' => '0',
290
	'min_ver' => '0.300'
291
     },
292
    'CGI::Emulate::PSGI' => {
293
	'usage' => 'PLACK',
294
	'required' => '0',
295
	'min_ver' => '0.10'
296
    },
297
    'CGI::Compile' => {
298
	'usage' => 'PLACK CGI Compilation',
299
	'required' => '0',
300
	'min_ver' => '0.15'
301
    },
302
    'Plack::Middleware::Debug' => {
303
	'usage' => 'PLACK Debugging',
304
	'required' => '0',
305
	'min_ver' => '0.1'
306
    },
287
    'Class::Factory::Util' => {
307
    'Class::Factory::Util' => {
288
        'usage'    => 'Core',
308
        'usage'    => 'Core',
289
        'required' => '1',
309
        'required' => '1',
(-)a/Makefile.PL (-2 / +57 lines)
Lines 298-303 my $target_map = { Link Here
298
  './skel'                      => 'NONE',
298
  './skel'                      => 'NONE',
299
  './skel/var/log/koha'         => { target => 'LOG_DIR', trimdir => -1 },
299
  './skel/var/log/koha'         => { target => 'LOG_DIR', trimdir => -1 },
300
  './skel/var/spool/koha'       => { target => 'BACKUP_DIR', trimdir => -1 },
300
  './skel/var/spool/koha'       => { target => 'BACKUP_DIR', trimdir => -1 },
301
  './skel/var/run/koha/plack' => { target => 'PLACK_RUN_DIR', trimdir => -1 },
301
  './skel/var/run/koha/zebradb' => { target => 'ZEBRA_RUN_DIR', trimdir => -1 },
302
  './skel/var/run/koha/zebradb' => { target => 'ZEBRA_RUN_DIR', trimdir => -1 },
302
  './skel/var/lock/koha/zebradb/authorities' => { target => 'ZEBRA_LOCK_DIR', trimdir => 6 },
303
  './skel/var/lock/koha/zebradb/authorities' => { target => 'ZEBRA_LOCK_DIR', trimdir => 6 },
303
  './skel/var/lib/koha/zebradb/authorities/key'  => { target => 'ZEBRA_DATA_DIR', trimdir => 6 },
304
  './skel/var/lib/koha/zebradb/authorities/key'  => { target => 'ZEBRA_DATA_DIR', trimdir => 6 },
Lines 345-350 Koha from a git clone with no fuss). Link Here
345
Directory under which most components will go.  Default
346
Directory under which most components will go.  Default
346
value will vary depending on INSTALL_MODE.
347
value will vary depending on INSTALL_MODE.
347
348
349
=item INTRANET_DNS
350
351
Set the DNS entry for staff client
352
353
=item OPAC_DNS
354
355
Set the DNS entry for OPAC
356
357
=item INTRANET_PORT
358
359
Set the port for the staff client
360
361
=item OPAC_PORT
362
363
Set the port for the OPAC
364
348
=item DB_TYPE
365
=item DB_TYPE
349
366
350
Type of DBMS (e.g., mysql or Pg).
367
Type of DBMS (e.g., mysql or Pg).
Lines 405-410 System group that will own Koha's files. Link Here
405
422
406
# default configuration options
423
# default configuration options
407
my %config_defaults = (
424
my %config_defaults = (
425
  'INTRANET_DNS'      => 'localhost',
426
  'OPAC_DNS'          => 'localhost',
427
  'INTRANET_PORT'     => '8080',
428
  'OPAC_PORT'         => '80',
408
  'DB_TYPE'           => 'mysql',
429
  'DB_TYPE'           => 'mysql',
409
  'DB_HOST'           => 'localhost',
430
  'DB_HOST'           => 'localhost',
410
  'DB_NAME'           => 'koha',
431
  'DB_NAME'           => 'koha',
Lines 496-504 get_file_map($target_map, $dirtree, $file_map, $config{'INSTALL_ZEBRA'} eq "yes" Link Here
496
my $pl_files = {
517
my $pl_files = {
497
      'rewrite-config.PL' => [
518
      'rewrite-config.PL' => [
498
         'blib/KOHA_CONF_DIR/koha-conf.xml',
519
         'blib/KOHA_CONF_DIR/koha-conf.xml',
499
         'blib/KOHA_CONF_DIR/koha-httpd.conf',
520
         'blib/KOHA_CONF_DIR/koha-nginx.conf',
500
         'blib/ZEBRA_CONF_DIR/etc/default.idx',
521
         'blib/ZEBRA_CONF_DIR/etc/default.idx',
501
         'blib/MISC_DIR/koha-install-log'
522
         'blib/MISC_DIR/koha-install-log',
523
	 'blib/KOHA_CONF_DIR/koha-httpd.conf',
524
	 'blib/SCRIPT_DIR/koha.psgi',
525
	 'blib/SCRIPT_DIR/koha-plack.sh',
502
         ],
526
         ],
503
	  'fix-perl-path.PL' => [	# this script ensures the correct shebang line for the platform installed on...
527
	  'fix-perl-path.PL' => [	# this script ensures the correct shebang line for the platform installed on...
504
		 'blib'
528
		 'blib'
Lines 559-564 my %test_suite_override_dirs = ( Link Here
559
    ZEBRA_LOCK_DIR => ['var', 'lock', 'zebradb'],
583
    ZEBRA_LOCK_DIR => ['var', 'lock', 'zebradb'],
560
    ZEBRA_DATA_DIR => ['var', 'lib', 'zebradb'],
584
    ZEBRA_DATA_DIR => ['var', 'lib', 'zebradb'],
561
    ZEBRA_RUN_DIR  => ['var', 'run', 'zebradb'],
585
    ZEBRA_RUN_DIR  => ['var', 'run', 'zebradb'],
586
    PLACK_RUN_DIR  => ['var', 'run', 'plack'],
562
);
587
);
563
588
564
WriteMakefile(
589
WriteMakefile(
Lines 865-870 Group); Link Here
865
    }
890
    }
866
891
867
    $msg = q(
892
    $msg = q(
893
Please specify if you would like a DNS
894
entry for the Koha Staff Client.
895
896
Intranet DNS Settings);
897
    $config{'INTRANET_DNS'} = _get_value('INTRANET_DNS', $msg, $defaults->{'INTRANET_DNS'}, $valid_values, $install_log_values);
898
899
    $msg = q(
900
Please specify if you would like a DNS
901
entry for the Koha OPAC.
902
903
OPAC DNS Settings);
904
    $config{'OPAC_DNS'} = _get_value('OPAC_DNS', $msg, $defaults->{'OPAC_DNS'}, $valid_values, $install_log_values);
905
906
    $msg = q(
907
Please specify the port you would
908
like the Koha Staff Client to use.
909
910
Intranet Port Settings);
911
    $config{'INTRANET_PORT'} = _get_value('INTRANET_PORT', $msg, $defaults->{'INTRANET_PORT'}, $valid_values, $install_log_values);
912
    $msg = q(
913
Please specify the port you would
914
like the Koha OPAC to use.
915
916
OPAC Port Settings);
917
    $config{'OPAC_PORT'} = _get_value('OPAC_PORt', $msg, $defaults->{'OPAC_PORT'}, $valid_values, $install_log_values);
918
919
    $msg = q(
868
Please specify which database engine you will use
920
Please specify which database engine you will use
869
to store data in Koha.  The choices are MySQL and
921
to store data in Koha.  The choices are MySQL and
870
PostgreSQL; please note that at the moment
922
PostgreSQL; please note that at the moment
Lines 1237-1242 sub get_target_directories { Link Here
1237
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'spool');
1289
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'spool');
1238
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
1290
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
1239
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
1291
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
1292
        $dirmap{'PLACK_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'plack');
1240
    } elsif ($mode eq 'dev') {
1293
    } elsif ($mode eq 'dev') {
1241
        my $curdir = File::Spec->rel2abs(File::Spec->curdir());
1294
        my $curdir = File::Spec->rel2abs(File::Spec->curdir());
1242
        $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir($curdir);
1295
        $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir($curdir);
Lines 1267-1272 sub get_target_directories { Link Here
1267
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'spool');
1320
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'spool');
1268
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
1321
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
1269
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
1322
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
1323
        $dirmap{'PLACK_RUN_DIR'} =  File::Spec->catdir(@basedir, $package, 'var', 'run', 'plack');
1270
    } else {
1324
    } else {
1271
        # mode is standard, i.e., 'fhs'
1325
        # mode is standard, i.e., 'fhs'
1272
        $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'cgi-bin');
1326
        $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'cgi-bin');
Lines 1289-1294 sub get_target_directories { Link Here
1289
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'spool', $package);
1343
        $dirmap{'BACKUP_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'spool', $package);
1290
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'lib', $package, 'zebradb');
1344
        $dirmap{'ZEBRA_DATA_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'lib', $package, 'zebradb');
1291
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'run', $package, 'zebradb');
1345
        $dirmap{'ZEBRA_RUN_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'run', $package, 'zebradb');
1346
        $dirmap{'PLACK_RUN_DIR'} =  File::Spec->catdir(File::Spec->rootdir(), 'var', 'run', $package, 'plack');
1292
    }
1347
    }
1293
1348
1294
    _get_env_overrides(\%dirmap);
1349
    _get_env_overrides(\%dirmap);
(-)a/debian/control (-6 / +16 lines)
Lines 6-18 Standards-Version: 3.8.4 Link Here
6
# NOTA BENE: Build dependencies end up as runtime dependencies as well.
6
# NOTA BENE: Build dependencies end up as runtime dependencies as well.
7
# See debian/rules, the override_dh_gencontrol rules. 
7
# See debian/rules, the override_dh_gencontrol rules. 
8
# There are some exceptions.
8
# There are some exceptions.
9
Build-Depends: libalgorithm-checkdigits-perl,
9
Build-Depends: EEEK: unknown package for AnyEvent::HTTP,
10
 libanyevent-http-perl,
10
 EEEK: unknown package for Data::Pagination,
11
 EEEK: unknown package for Data::Paginator,
12
 EEEK: unknown package for Plack::Middleware::Debug,
13
 EEEK: unknown package for Starman,
14
 libalgorithm-checkdigits-perl,
11
 libanyevent-perl,
15
 libanyevent-perl,
12
 libauthen-cas-client-perl,
16
 libauthen-cas-client-perl,
13
 libbiblio-endnotestyle-perl,
17
 libbiblio-endnotestyle-perl,
14
 libbusiness-isbn-perl,
18
 libbusiness-isbn-perl,
15
 libcache-memcached-fast-perl,
19
 libcache-memcached-fast-perl,
20
 libcgi-compile-perl,
21
 libcgi-emulate-psgi-perl,
16
 libcgi-pm-perl | perl-modules,
22
 libcgi-pm-perl | perl-modules,
17
 libcgi-session-driver-memcached-perl,
23
 libcgi-session-driver-memcached-perl,
18
 libcgi-session-perl,
24
 libcgi-session-perl,
Lines 20-26 Build-Depends: libalgorithm-checkdigits-perl, Link Here
20
 libclass-accessor-perl,
26
 libclass-accessor-perl,
21
 libclass-factory-util-perl,
27
 libclass-factory-util-perl,
22
 libdata-ical-perl,
28
 libdata-ical-perl,
23
 libdata-paginator-perl,
24
 libdate-calc-perl,
29
 libdate-calc-perl,
25
 libdate-manip-perl,
30
 libdate-manip-perl,
26
 libdatetime-event-ical-perl,
31
 libdatetime-event-ical-perl,
Lines 182-194 Description: Other dep. for koha Link Here
182
 daemon, debconf, etc.).
187
 daemon, debconf, etc.).
183
188
184
Package: koha-perldeps
189
Package: koha-perldeps
185
Depends: libalgorithm-checkdigits-perl,
190
Depends: EEEK: unknown package for AnyEvent::HTTP,
186
 libanyevent-http-perl,
191
 EEEK: unknown package for Data::Pagination,
192
 EEEK: unknown package for Data::Paginator,
193
 EEEK: unknown package for Plack::Middleware::Debug,
194
 EEEK: unknown package for Starman,
195
 libalgorithm-checkdigits-perl,
187
 libanyevent-perl,
196
 libanyevent-perl,
188
 libauthen-cas-client-perl,
197
 libauthen-cas-client-perl,
189
 libbiblio-endnotestyle-perl,
198
 libbiblio-endnotestyle-perl,
190
 libbusiness-isbn-perl,
199
 libbusiness-isbn-perl,
191
 libcache-memcached-fast-perl,
200
 libcache-memcached-fast-perl,
201
 libcgi-compile-perl,
202
 libcgi-emulate-psgi-perl,
192
 libcgi-pm-perl | perl-modules,
203
 libcgi-pm-perl | perl-modules,
193
 libcgi-session-driver-memcached-perl,
204
 libcgi-session-driver-memcached-perl,
194
 libcgi-session-perl,
205
 libcgi-session-perl,
Lines 196-202 Depends: libalgorithm-checkdigits-perl, Link Here
196
 libclass-accessor-perl,
207
 libclass-accessor-perl,
197
 libclass-factory-util-perl,
208
 libclass-factory-util-perl,
198
 libdata-ical-perl,
209
 libdata-ical-perl,
199
 libdata-paginator-perl,
200
 libdate-calc-perl,
210
 libdate-calc-perl,
201
 libdate-manip-perl,
211
 libdate-manip-perl,
202
 libdatetime-event-ical-perl,
212
 libdatetime-event-ical-perl,
(-)a/etc/koha-httpd.conf (-6 / +6 lines)
Lines 3-13 Link Here
3
#NameVirtualHost *
3
#NameVirtualHost *
4
4
5
## OPAC
5
## OPAC
6
<VirtualHost __WEBSERVER_IP__:__WEBSERVER_PORT__>
6
<VirtualHost __OPAC_DNS__:__OPAC_PORT__>
7
   ServerAdmin  __WEBMASTER_EMAIL__
7
   ServerAdmin  __WEBMASTER_EMAIL__
8
   DocumentRoot __OPAC_WWW_DIR__
8
   DocumentRoot __OPAC_WWW_DIR__
9
   ServerName __WEBSERVER_HOST__
9
   ServerName __OPAC_DNS__:__OPAC_PORT__
10
#  ServerAlias opac.mydomain.com
10
#  ServerAlias __OPAC_DNS__
11
   ScriptAlias /cgi-bin/koha/ "__OPAC_CGI_DIR__/opac/"
11
   ScriptAlias /cgi-bin/koha/ "__OPAC_CGI_DIR__/opac/"
12
   ScriptAlias /index.html "__OPAC_CGI_DIR__/opac/opac-main.pl"
12
   ScriptAlias /index.html "__OPAC_CGI_DIR__/opac/opac-main.pl"
13
   ScriptAlias /opac-search.pl "__OPAC_CGI_DIR__/opac/opac-search.pl"
13
   ScriptAlias /opac-search.pl "__OPAC_CGI_DIR__/opac/opac-search.pl"
Lines 97-107 Link Here
97
</VirtualHost>
97
</VirtualHost>
98
98
99
## Intranet
99
## Intranet
100
<VirtualHost __WEBSERVER_IP__:__WEBSERVER_PORT_LIBRARIAN__>
100
<VirtualHost __INTRANET_DNS__:__INTRANET_PORT__>
101
   ServerAdmin __WEBMASTER_EMAIL__
101
   ServerAdmin __WEBMASTER_EMAIL__
102
   DocumentRoot __INTRANET_WWW_DIR__
102
   DocumentRoot __INTRANET_WWW_DIR__
103
   ServerName __WEBSERVER_HOST__:__WEBSERVER_PORT_LIBRARIAN__
103
   ServerName __INTRANET_DNS__:__INTRANET_PORT__
104
#  ServerAlias intranet.mydomain.com
104
#  ServerAlias __INTRANET_DNS__
105
   ScriptAlias /cgi-bin/koha/ "__INTRANET_CGI_DIR__/"
105
   ScriptAlias /cgi-bin/koha/ "__INTRANET_CGI_DIR__/"
106
   ScriptAlias /index.html "__INTRANET_CGI_DIR__/mainpage.pl"
106
   ScriptAlias /index.html "__INTRANET_CGI_DIR__/mainpage.pl"
107
   ScriptAlias /search "__INTRANET_CGI_DIR__/search.pl"
107
   ScriptAlias /search "__INTRANET_CGI_DIR__/search.pl"
(-)a/etc/koha-nginx.conf (+52 lines)
Line 0 Link Here
1
upstream backendurl {
2
      server unix:__PLACK_RUN_DIR__/plack.sock;
3
}
4
5
server {
6
    listen __OPAC_PORT__;
7
    server_name __OPAC_DNS__;
8
    access_log  __LOG_DIR__/nginx-opac-access.log;
9
    root        __OPAC_WWW_DIR__;
10
11
    rewrite ^/$ /cgi-bin/koha/opac-main.pl;
12
    rewrite ^/cgi-bin/koha/(.*)$ /cgi-bin/koha/opac/$1;
13
14
    location    / {
15
        try_files $uri @plack;
16
    }
17
    location /opac-tmpl/ {
18
        root __OPAC_WWW_DIR__;
19
     }
20
21
    location @plack {
22
        proxy_set_header Host $http_host;
23
        proxy_set_header X-Forwarded-Host $host;
24
        proxy_set_header X-Real-IP $remote_addr;
25
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
26
        proxy_pass  http://backendurl;
27
    }
28
}
29
30
server {
31
    listen __INTRANET_PORT__;
32
    server_name __INTRANET_DNS__;
33
    access_log  __LOG_DIR__/nginx-intranet-access.log;
34
    root        __INTRANET_WWW_DIR__;
35
36
    rewrite ^/$ /cgi-bin/koha/mainpage.pl;
37
38
    location    / {
39
        try_files $uri @plack;
40
    }
41
    location /intranet-tmpl/ {
42
        root __INTRANET_WWW_DIR__;
43
     }
44
45
    location @plack {
46
        proxy_set_header Host $http_host;
47
        proxy_set_header X-Forwarded-Host $host;
48
        proxy_set_header X-Real-IP $remote_addr;
49
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
50
        proxy_pass  http://backendurl;
51
    }
52
}
(-)a/misc/bin/koha-plack.sh (+73 lines)
Line 0 Link Here
1
#!/bin/sh -e
2
3
# This file is part of Koha.
4
#
5
# Koha is free software; you can redistribute it and/or modify it under the
6
# terms of the GNU General Public License as published by the Free Software
7
# Foundation; either version 3 of the License, or (at your option) any later
8
# version.
9
#
10
# Koha is distributed in the hope that it will be useful, but WITHOUT ANY
11
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
12
# A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
13
#
14
# You should have received a copy of the GNU General Public License along with
15
# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
16
# Suite 330, Boston, MA  02111-1307 USA
17
18
### BEGIN INIT INFO# Provides:          koha-plack
19
# Required-Start:    $syslog $remote_fs
20
# Required-Stop:     $syslog $remote_fs# Default-Start:     2 3 4 5
21
# Default-Stop:      0 1 6# Short-Description: Plack server for Koha
22
### END INIT INFO
23
24
export KOHA_CONF=__KOHA_CONF_DIR__/koha-conf.xml
25
#export OPACDIR=__OPAC_WWW_DIR__
26
#export INTRANETDIR=__OPAC_WWW_DIR__
27
export LOGDIR=__LOG_DIR__
28
USER=__KOHA_USER__
29
GROUP=__KOHA_GROUP__
30
RUNDIR=__PLACK_RUN_DIR__
31
PIDFILE=$RUNDIR/plack.pid
32
33
# Use one of these lines to choose between TCP port and UNIX socket listeners
34
SOCKET=$RUNDIR/plack.sock
35
#PORT=5000
36
37
case "$1" in
38
    start)
39
	echo "Starting Koha Plack Daemon"
40
41
      # create run and lock directories if needed;
42
      # /var/run and /var/lock are completely cleared at boot
43
      # on some platforms
44
      if [ ! -d $RUNDIR ]; then
45
        umask 022
46
        mkdir -p $RUNDIR
47
        if [ $EUID -eq 0 ]; then
48
            chown $USER:$GROUP $RUNDIR
49
        fi
50
      fi
51
52
        opt="$opt --access-log $LOGDIR/koha-access.log --error-log $LOGDIR/koha-error.log"
53
        opt="$opt -M FindBin --max-requests 50 --workers 2 -E deployment"
54
        if [ $SOCKET ]; then
55
            opt="$opt --listen $SOCKET -D --pid $PIDFILE"
56
        elif [ $PORT ]; then
57
            opt="$opt --port $PORT -D --pid $PIDFILE"
58
        fi
59
        starman $opt __SCRIPT_DIR__/koha.psgi
60
61
        if [ $SOCKET ]; then
62
            chown $USER:$GROUP $SOCKET
63
	    chmod 660 $SOCKET
64
        fi
65
        ;;
66
    stop)
67
        start-stop-daemon --stop --pidfile $PIDFILE
68
        ;;
69
    *)
70
        echo "Usage: koha-plack {start|stop}"
71
        exit 1
72
        ;;
73
esac
(-)a/misc/bin/koha.psgi (+43 lines)
Line 0 Link Here
1
#!/usr/bin/perl
2
3
BEGIN {
4
    $ENV{'KOHA_CONF'} = '__KOHA_CONF_DIR__/koha-conf.xml';
5
    $ENV{'PERL5LIB'} = '__PERL_MODULE_DIR__';
6
}
7
8
use lib("__PERL_MODULE_DIR__");
9
use lib("__PERL_MODULE_DIR__/installer");
10
use Plack::Builder;
11
use Plack::App::CGIBin;
12
use Plack::App::Directory;
13
use Plack::Middleware::Debug;
14
use Plack::App::URLMap;
15
use C4::Context;
16
use C4::Languages;
17
use C4::Members;
18
use C4::Dates;
19
use C4::Boolean;
20
use C4::Letters;
21
use C4::Koha;
22
use C4::XSLT;
23
use C4::Branch;
24
use C4::Category;
25
26
C4::Context->disable_syspref_cache();
27
28
my $intra=Plack::App::CGIBin->new(root => "__INTRANET_CGI_DIR__" );
29
30
my $opac = Plack::App::CGIBin->new(root => "__OPAC_CGI_DIR__");
31
my $panels = Plack::Middleware::Debug->default_panels;
32
builder {
33
    enable_if{
34
	$ENV{DEBUG}
35
    } 'Debug',  panels => [[ 'DBITrace', level => 1 ], @$panels ];
36
37
    enable "Plack::Middleware::Static";
38
39
    enable 'StackTrace';
40
41
    mount '/cgi-bin/koha/' => $intra;
42
    mount '/cgi-bin/koha/' => $opac;
43
};
(-)a/rewrite-config.PL (-1 / +6 lines)
Lines 82-87 $prefix = $ENV{'INSTALL_BASE'} || "/usr"; Link Here
82
%configuration = (
82
%configuration = (
83
  "__KOHA_INSTALLED_VERSION__" => "no_version_found",
83
  "__KOHA_INSTALLED_VERSION__" => "no_version_found",
84
  "__LOG_DIR__" => "/var/log",
84
  "__LOG_DIR__" => "/var/log",
85
  "__WEBSERVER__" => "apache2",
86
  "__INTRANET_DNS__" => "localhost",
87
  "__OPAC_DNS__" => "localhost",
88
  "__OPAC_PORT__" => "80",
89
  "__INTRANET_PORT__" => "8080",
85
  "__DB_TYPE__" => "mysql",
90
  "__DB_TYPE__" => "mysql",
86
  "__DB_NAME__" => "koha",
91
  "__DB_NAME__" => "koha",
87
  "__DB_HOST__" => $myhost,
92
  "__DB_HOST__" => $myhost,
Lines 119-124 $prefix = $ENV{'INSTALL_BASE'} || "/usr"; Link Here
119
  '__ZEBRA_LOCK_DIR__' => "$prefix/var/lock/zebradb",
124
  '__ZEBRA_LOCK_DIR__' => "$prefix/var/lock/zebradb",
120
  '__ZEBRA_DATA_DIR__' => "$prefix/var/lib/zebradb",
125
  '__ZEBRA_DATA_DIR__' => "$prefix/var/lib/zebradb",
121
  '__ZEBRA_RUN_DIR__' => "$prefix/var/run/zebradb",
126
  '__ZEBRA_RUN_DIR__' => "$prefix/var/run/zebradb",
127
  '__PLACK_RUN_DIR__' => "$prefix/var/run/plack",
122
  '__ZEBRA_MARC_FORMAT__' => 'marc21',
128
  '__ZEBRA_MARC_FORMAT__' => 'marc21',
123
  '__ZEBRA_LANGUAGE__' => 'en',
129
  '__ZEBRA_LANGUAGE__' => 'en',
124
  '__ZEBRA_TOKENIZER_STMT__' => 'charmap word-phrase-utf.chr',
130
  '__ZEBRA_TOKENIZER_STMT__' => 'charmap word-phrase-utf.chr',
125
- 

Return to bug 9316