Bugzilla – Attachment 63493 Details for
Bug 18617
starting plack on reboot can fail on non-standard apache configs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18617 - starting plack on reboot can fail on non-standard apache configs
Bug-18617---starting-plack-on-reboot-can-fail-on-n.patch (text/plain), 2.82 KB, created by
Liz Rea
on 2017-05-17 00:02:33 UTC
(
hide
)
Description:
Bug 18617 - starting plack on reboot can fail on non-standard apache configs
Filename:
MIME Type:
Creator:
Liz Rea
Created:
2017-05-17 00:02:33 UTC
Size:
2.82 KB
patch
obsolete
>From 9ef7ff99cb490705d3c35a9308ab1df7fe61fd2f Mon Sep 17 00:00:00 2001 >From: Liz Rea <liz@catalyst.net.nz> >Date: Wed, 17 May 2017 11:37:22 +1200 >Subject: [PATCH] Bug 18617 - starting plack on reboot can fail on non-standard > apache configs > >To test: >apply this patch >copy debian/scripts/koha-functions.sh to /usr/share/koha/bin >copy debian/scripts/koha-plack to /usr/sbin > >create a dummy instance if you need to (koha-create --create-db whatever) >enable plack - koha-plack --enable whatever >check for existence of /var/lib/koha/whatever/plack.enabled >do a koha-list --enabled --plack and your instance should be listed as enabled. >rename your /etc/apache2/sites-available/whatever.conf to something else >do a koha-list --enabled --plack - it should still be enabled >do a koha-plack --disable whatever - it should remove /var/lib/koha/whatever/plack.enabled >do a koha-list --enabled --plack - it should not be listed. > >Note: >This does not deal with the issue of disabling plack not doing the right thing for config files that are not "/etc/apache2/sites-available/whatever.conf" - this only ensures that koha-list --enabled and --disabled reports correctly in that circumstance. >--- > debian/scripts/koha-functions.sh | 2 ++ > debian/scripts/koha-plack | 2 ++ > 2 files changed, 4 insertions(+) > >diff --git a/debian/scripts/koha-functions.sh b/debian/scripts/koha-functions.sh >index 256ae2b..e628990 100755 >--- a/debian/scripts/koha-functions.sh >+++ b/debian/scripts/koha-functions.sh >@@ -199,6 +199,8 @@ is_plack_enabled() > grep -q '^[[:space:]]*Include /etc/koha/apache-shared-intranet-plack.conf' \ > "$instancefile" ; then > return 0 >+ elif [ -e /var/lib/koha/$instancename/plack.enabled ]; then >+ return 0 > else > return 1 > fi >diff --git a/debian/scripts/koha-plack b/debian/scripts/koha-plack >index 5e1fc9c..46ac08b 100755 >--- a/debian/scripts/koha-plack >+++ b/debian/scripts/koha-plack >@@ -154,6 +154,7 @@ enable_plack() > #Â Uncomment the plack related lines for OPAC and intranet > sed -i 's:^\s*#\(\s*Include /etc/koha/apache-shared-opac-plack.conf\)$:\1:' "$instancefile" > sed -i 's:^\s*#\(\s*Include /etc/koha/apache-shared-intranet-plack.conf\)$:\1:' "$instancefile" >+ touch /var/lib/koha/$instancename/plack.enabled > [ "${quiet}" != "yes" ] && warn "Plack enabled for ${instancename}" > return 0 > else >@@ -171,6 +172,7 @@ disable_plack() > #Â Comment out the plack related lines for OPAC and intranet > sed -i 's:^\(\s*Include /etc/koha/apache-shared-opac-plack.conf\)$:#\1:' "$instancefile" > sed -i 's:^\(\s*Include /etc/koha/apache-shared-intranet-plack.conf\)$:#\1:' "$instancefile" >+ rm /var/lib/koha/$instancename/plack.enabled > [ "${quiet}" != "yes" ] && warn "Plack disabled for ${instancename}" > return 0 > else >-- >2.7.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18617
: 63493 |
70971