Koha/debian/scripts
Andreas Roussos f12dabe6cc Bug 21440: koha-create expects the file passed by $DEFAULTSQL to be in gzip format
koha-create contains a call to `zcat` which fails if the file passed
as an argument is not in gzip format.

This patch fixes the issue by adding the -f flag to the zcat call in
koha-create, as per the top-voted answers in the following SE URLs:
https://unix.stackexchange.com/a/77309
https://unix.stackexchange.com/a/131944

Test plan:
1) in /etc/koha/koha-sites.conf, set the DEFAULTSQL variable to point
   to an _uncompressed_ SQL database dump
2) run `koha-create --create-db instance` and notice how it fails with:
   gzip: /path/to/dump.sql: not in gzip format
3) apply the patch
4) notice the extra line of information "The SQL file can be optionally
   compressed with gzip" in koha-sites.conf
5) run the `koha-create` command again, this time it should work
6) repeat with DEFAULTSQL pointing to a gzip'd dump, it should work too

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
2018-10-09 09:59:10 +00:00
..
koha-create Bug 21440: koha-create expects the file passed by $DEFAULTSQL to be in gzip format 2018-10-09 09:59:10 +00:00
koha-create-dirs Bug 20428: (QA follow-up) Remove redundant directory level 2018-05-14 10:36:39 -03:00
koha-disable Bug 20234: Make maintenance scripts use koha-zebra instead of koha-*-zebra 2018-02-27 15:58:33 -03:00
koha-dump
koha-dump-defaults
koha-elasticsearch Bug 19462: Add a koha-elasticsearch command 2017-10-27 14:10:31 -03:00
koha-email-disable
koha-email-enable
koha-enable
koha-enable-sip
koha-foreach Bug 17717: (QA follow-up) Fix typo chdir 2018-03-15 08:22:05 +00:00
koha-functions.sh Bug 18913: Allow symbolic link in /etc/koha/sites 2018-02-19 16:41:00 -03:00
koha-indexer Bug 18554: Adjust a few typos including responsability 2017-05-09 21:03:22 +00:00
koha-list
koha-mysql
koha-mysqlcheck
koha-passwd
koha-plack Bug 20079: Display stack trace for development installations 2018-07-18 17:00:20 +00:00
koha-rebuild-zebra Bug 20795: Inform the user about this change, add to pod 2018-08-14 12:35:13 +00:00
koha-remove Bug 20234: Make maintenance scripts use koha-zebra instead of koha-*-zebra 2018-02-27 15:58:33 -03:00
koha-reset-passwd
koha-restore
koha-run-backups
koha-shell Bug 18502: Make koha-shell set the right PERL5LIB on dev installs 2017-05-05 12:12:04 -03:00
koha-sitemap Bug 16733: Adjust other debian scripts using PERL5LIB 2017-01-20 14:15:27 +00:00
koha-start-sip Bug 16733: Adjust other debian scripts using PERL5LIB 2017-01-20 14:15:27 +00:00
koha-stop-sip Bug 16733: Adjust other debian scripts using PERL5LIB 2017-01-20 14:15:27 +00:00
koha-translate Bug 21481: Remove reference of *-staff-help.po from koha-translate 2018-10-05 15:02:59 +00:00
koha-upgrade-schema Bug 16749: Add is_instance check to koha-upgrade-schema 2017-02-17 13:20:58 +00:00
koha-upgrade-to-3.4
koha-zebra Bug 20745: koha-zebra doesn't return the correct error codes 2018-05-11 10:52:44 -03:00