Bug 18562: Add koha-sip maintenance script
authorTomas Cohen Arazi <tomascohen@theke.io>
Wed, 30 Jan 2019 11:42:53 +0000 (08:42 -0300)
committerroot <root@f1ebe1bec408>
Mon, 11 Feb 2019 18:30:09 +0000 (18:30 +0000)
commit6ec979057b2b4f10fe469d2655fa0fcb47af1cb7
treef1ec3558dd45c193a0670210a5d10fed6316dee3
parentae258098d9cfbc6d6ea211f8bcbb6c50c15b0ecd
Bug 18562: Add koha-sip maintenance script

This patch introduces a single script to handle all actions on SIP
servers for Koha instances. It is intended to be a replacement for:

- koha-start-sip
- koha-stop-sip
- koha-enable-sip

It adds a function called is_sip_running to koha-functions.sh.

To test:
- Apply this patch
- Run:
  $ misc4dev/cp_debian_files.pl
  $ sudo koha-sip --enable kohadev
  $ sudo koha-sip --start kohadev
  $ sudo koha-sip --status kohadev
=> SUCCESS: The SIP server is running for kohadev
- Run:
  $ sudo koha-sip --restart --verbose kohadev
  $ sudo koha-sip --status kohadev
=> SUCCESS: The SIP server is running for kohadev
- Run:
  $ sudo koha-sip --stop kohadev
  $ sudo koha-sip --status kohadev
=> SUCCESS: The SIP server is not running for kohadev
- Play with other combinations like enabling an already enabled
instance, etc. Remember you need to remove the
/etc/koha/sites/kohadev/SIPconfig.xml file so it is considered disabled.
- Sign off :-D

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
debian/koha-common.install
debian/scripts/koha-functions.sh
debian/scripts/koha-sip [new file with mode: 0755]