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

(-)a/debian/docs/koha-create.xml (+16 lines)
Lines 37-42 Link Here
37
      <arg><option>--passwdfile</option> /path/to/passwd</arg>
37
      <arg><option>--passwdfile</option> /path/to/passwd</arg>
38
      <arg><option>--database</option> database</arg>
38
      <arg><option>--database</option> database</arg>
39
      <arg><option>--adminuser</option> n</arg>
39
      <arg><option>--adminuser</option> n</arg>
40
      <arg><option>--enable-sru</option></arg>
41
      <arg><option>--sru-port</option> port</arg>
40
      <arg><option>--help</option>|<option>-h</option></arg>
42
      <arg><option>--help</option>|<option>-h</option></arg>
41
43
42
      <arg choice="req" rep="norepeat"><replaceable>instancename</replaceable></arg>
44
      <arg choice="req" rep="norepeat"><replaceable>instancename</replaceable></arg>
Lines 152-157 Link Here
152
    </varlistentry>
154
    </varlistentry>
153
155
154
    <varlistentry>
156
    <varlistentry>
157
      <term><option>--enable-sru</option></term>
158
      <listitem>
159
        <para>Enable the SRU server for the created instance.</para>
160
      </listitem>
161
    </varlistentry>
162
163
    <varlistentry>
164
      <term><option>--sru-port</option></term>
165
      <listitem>
166
        <para>Specifiy a <option> TCP port number</option> for the SRU server to listen on.</para>
167
      </listitem>
168
    </varlistentry>
169
170
    <varlistentry>
155
      <term><option>--help</option>,<option>-h</option></term>
171
      <term><option>--help</option>,<option>-h</option></term>
156
      <listitem>
172
      <listitem>
157
        <para>Print usage information.</para>
173
        <para>Print usage information.</para>
(-)a/debian/scripts/koha-create (-1 / +33 lines)
Lines 60-65 Options: Link Here
60
  --use-memcached           Set the instance to make use of memcache.
60
  --use-memcached           Set the instance to make use of memcache.
61
  --memcached-servers str   Set a comma-separated list of host:port memcached servers.
61
  --memcached-servers str   Set a comma-separated list of host:port memcached servers.
62
  --memcached-prefix str    Set the desired prefix for the instance memcached namespace.
62
  --memcached-prefix str    Set the desired prefix for the instance memcached namespace.
63
  --enable-sru              Enable the SRU server (default: disabled).
64
  --sru-port                Specifiy a TCP port number for the SRU server to listen on.
65
                            (default: 7090).
63
  --defaultsql some.sql     Specify a default SQL file to be loaded on the DB.
66
  --defaultsql some.sql     Specify a default SQL file to be loaded on the DB.
64
  --configfile cfg_file     Specify an alternate config file for reading default values.
67
  --configfile cfg_file     Specify an alternate config file for reading default values.
65
  --passwdfile passwd       Specify an alternate passwd file.
68
  --passwdfile passwd       Specify an alternate passwd file.
Lines 87-92 generate_config_file() { Link Here
87
        -e "s/__ZEBRA_PASS__/$zebrapwd/g" \
90
        -e "s/__ZEBRA_PASS__/$zebrapwd/g" \
88
        -e "s/__ZEBRA_MARC_FORMAT__/$ZEBRA_MARC_FORMAT/g" \
91
        -e "s/__ZEBRA_MARC_FORMAT__/$ZEBRA_MARC_FORMAT/g" \
89
        -e "s/__ZEBRA_LANGUAGE__/$ZEBRA_LANGUAGE/g" \
92
        -e "s/__ZEBRA_LANGUAGE__/$ZEBRA_LANGUAGE/g" \
93
        -e "s/__SRU_BIBLIOS_PORT__/$SRU_SERVER_PORT/g" \
94
        -e "s/__START_SRU_PUBLICSERVER__/$START_SRU_PUBLICSERVER/g" \
95
        -e "s/__END_SRU_PUBLICSERVER__/$END_SRU_PUBLICSERVER/g" \
90
        -e "s/__BIBLIOS_INDEXING_MODE__/$BIBLIOS_INDEXING_MODE/g" \
96
        -e "s/__BIBLIOS_INDEXING_MODE__/$BIBLIOS_INDEXING_MODE/g" \
91
        -e "s/__AUTHORITIES_INDEXING_MODE__/$AUTHORITIES_INDEXING_MODE/g" \
97
        -e "s/__AUTHORITIES_INDEXING_MODE__/$AUTHORITIES_INDEXING_MODE/g" \
92
        -e "s/__ZEBRA_BIBLIOS_CFG__/$ZEBRA_BIBLIOS_CFG/g" \
98
        -e "s/__ZEBRA_BIBLIOS_CFG__/$ZEBRA_BIBLIOS_CFG/g" \
Lines 280-285 set_memcached() Link Here
280
286
281
}
287
}
282
288
289
enable_sru_server()
290
{
291
    # remove the commenting symbols
292
    START_SRU_PUBLICSERVER=""
293
    END_SRU_PUBLICSERVER=""
294
    if [ "$SRU_SERVER_PORT" = "" ]; then
295
        # --sru-port not passed, use the default
296
        SRU_SERVER_PORT=$DEFAULT_SRU_SERVER_PORT
297
    fi
298
}
299
283
# Set defaults and read config file, if it exists.
300
# Set defaults and read config file, if it exists.
284
DOMAIN=""
301
DOMAIN=""
285
OPACPORT="80"
302
OPACPORT="80"
Lines 302-307 MEMCACHED_PREFIX="" Link Here
302
DEFAULT_MEMCACHED_SERVERS="127.0.0.1:11211"
319
DEFAULT_MEMCACHED_SERVERS="127.0.0.1:11211"
303
DEFAULT_MEMCACHED_PREFIX="koha_"
320
DEFAULT_MEMCACHED_PREFIX="koha_"
304
321
322
# SRU server variables
323
ENABLE_SRU="no"
324
SRU_SERVER_PORT=""
325
# hardcoded default SRU server port
326
DEFAULT_SRU_SERVER_PORT="7090"
327
START_SRU_PUBLICSERVER="<!--"
328
END_SRU_PUBLICSERVER="-->"
329
305
# Indexing mode variables (default is DOM)
330
# Indexing mode variables (default is DOM)
306
BIBLIOS_INDEXING_MODE="dom"
331
BIBLIOS_INDEXING_MODE="dom"
307
AUTHORITIES_INDEXING_MODE="dom"
332
AUTHORITIES_INDEXING_MODE="dom"
Lines 318-324 fi Link Here
318
343
319
[ $# -ge 1 ] && [ $# -le 16 ] || ( usage ; die "Error: wrong parameters" )
344
[ $# -ge 1 ] && [ $# -le 16 ] || ( usage ; die "Error: wrong parameters" )
320
345
321
TEMP=`getopt -o chrpm:l:d:f:b:a: -l create-db,request-db,populate-db,use-db,use-memcached,help,marcflavor:,auth-idx:,biblio-idx:,zebralang:,defaultsql:,configfile:,passwdfile:,database:,adminuser:,memcached-servers:,memcached-prefix:, \
346
TEMP=`getopt -o chrpm:l:d:f:b:a: -l create-db,request-db,populate-db,use-db,use-memcached,enable-sru,sru-port:,help,marcflavor:,auth-idx:,biblio-idx:,zebralang:,defaultsql:,configfile:,passwdfile:,database:,adminuser:,memcached-servers:,memcached-prefix:, \
322
     -n "$0" -- "$@"`
347
     -n "$0" -- "$@"`
323
348
324
# Note the quotes around `$TEMP': they are essential!
349
# Note the quotes around `$TEMP': they are essential!
Lines 369-374 while true ; do Link Here
369
            CLO_DATABASE="$2" ; shift 2 ;;
394
            CLO_DATABASE="$2" ; shift 2 ;;
370
        -a|--adminuser)
395
        -a|--adminuser)
371
            CLO_ADMINUSER="$2" ; shift 2 ;;
396
            CLO_ADMINUSER="$2" ; shift 2 ;;
397
        --enable-sru)
398
            ENABLE_SRU="yes" ; shift ;;
399
        --sru-port)
400
            SRU_SERVER_PORT="$2" ; shift 2 ;;
372
        -h|--help)
401
        -h|--help)
373
            usage ; exit 0 ;;
402
            usage ; exit 0 ;;
374
        --)
403
        --)
Lines 417-422 fi Link Here
417
446
418
set_biblios_indexing_mode $BIBLIOS_INDEXING_MODE $ZEBRA_MARC_FORMAT
447
set_biblios_indexing_mode $BIBLIOS_INDEXING_MODE $ZEBRA_MARC_FORMAT
419
448
449
if [ "$ENABLE_SRU" != "no" ]; then
450
    enable_sru_server
451
fi
420
452
421
if [ "$CLO_AUTHORITIES_INDEXING_MODE" !=  "" ]; then
453
if [ "$CLO_AUTHORITIES_INDEXING_MODE" !=  "" ]; then
422
    AUTHORITIES_INDEXING_MODE=$CLO_AUTHORITIES_INDEXING_MODE
454
    AUTHORITIES_INDEXING_MODE=$CLO_AUTHORITIES_INDEXING_MODE
(-)a/debian/templates/koha-conf-site.xml.in (-7 / +6 lines)
Lines 6-14 Link Here
6
<!-- Uncomment the following entry if you want to run the public Z39.50 server.
6
<!-- Uncomment the following entry if you want to run the public Z39.50 server.
7
    Also uncomment the <server> and <serverinfo> sections for id 'publicserver'
7
    Also uncomment the <server> and <serverinfo> sections for id 'publicserver'
8
    under PUBLICSERVER'S BIBLIOGRAPHIC RECORDS title-->
8
    under PUBLICSERVER'S BIBLIOGRAPHIC RECORDS title-->
9
<!--
9
__START_SRU_PUBLICSERVER__
10
<listen id="publicserver" >tcp:@:__ZEBRA_SRU_BIBLIOS_PORT__</listen>
10
<listen id="publicserver" >tcp:@:__SRU_BIBLIOS_PORT__</listen>
11
-->
11
__END_SRU_PUBLICSERVER__
12
12
13
<!-- Settings for special biblio server instance for PazPar2.
13
<!-- Settings for special biblio server instance for PazPar2.
14
     Because PazPar2 only connects to a Z39.50 server using TCP/IP,
14
     Because PazPar2 only connects to a Z39.50 server using TCP/IP,
Lines 171-178 Link Here
171
</serverinfo>
171
</serverinfo>
172
172
173
<!-- PUBLICSERVER'S BIBLIOGRAPHIC RECORDS -->
173
<!-- PUBLICSERVER'S BIBLIOGRAPHIC RECORDS -->
174
<!-- This can be used to set up a public Z39.50/SRU server.
174
<!-- This can be used to set up a public Z39.50/SRU server. -->
175
175
__START_SRU_PUBLICSERVER__
176
<server id="publicserver"  listenref="publicserver">
176
<server id="publicserver"  listenref="publicserver">
177
    <directory>/var/lib/koha/__KOHASITE__/biblios</directory>
177
    <directory>/var/lib/koha/__KOHASITE__/biblios</directory>
178
    <config>/etc/koha/sites/__KOHASITE__/__ZEBRA_BIBLIOS_CFG__</config>
178
    <config>/etc/koha/sites/__KOHASITE__/__ZEBRA_BIBLIOS_CFG__</config>
Lines 245-251 Link Here
245
        <user>kohauser</user>
245
        <user>kohauser</user>
246
        <password>__ZEBRA_PASS__</password>
246
        <password>__ZEBRA_PASS__</password>
247
</serverinfo>
247
</serverinfo>
248
-->
248
__END_SRU_PUBLICSERVER__
249
249
250
<config>
250
<config>
251
 <db_scheme>mysql</db_scheme>
251
 <db_scheme>mysql</db_scheme>
252
- 

Return to bug 12750