| Summary: | koha-plack contains a wrong test about missing Apache modules | ||
|---|---|---|---|
| Product: | Koha | Reporter: | Marcel de Rooy <m.de.rooy> |
| Component: | Architecture, internals, and plumbing | Assignee: | Bugs List <koha-bugs> |
| Status: | NEW --- | QA Contact: | Testopia <testopia> |
| Severity: | minor | ||
| Priority: | P5 - low | CC: | tomascohen |
| Version: | Main | ||
| Hardware: | All | ||
| OS: | All | ||
| GIT URL: | Initiative type: | --- | |
| Sponsorship status: | --- | Comma delimited list of Sponsors: | |
| Crowdfunding goal: | 0 | Patch complexity: | --- |
| Documentation contact: | Documentation submission: | ||
| Text to go in the release notes: | Version(s) released in: | ||
| Circulation function: | |||
/usr/sbin/apachectl -M 2>/dev/null | grep -q headers; echo "${PIPESTATUS[0]} ${PIPESTATUS[1]}"
1 1
Error fixed
/usr/sbin/apachectl -M 2>/dev/null | grep -q headers; echo "${PIPESTATUS[0]} ${PIPESTATUS[1]}"
/usr/sbin/apachectl -M 2>/dev/null | grep -q badheaders; echo "${PIPESTATUS[0]} ${PIPESTATUS[1]}"
0 1
(In reply to Marcel de Rooy from comment #2) > /usr/sbin/apachectl -M 2>/dev/null | grep -q headers; echo "${PIPESTATUS[0]} > ${PIPESTATUS[1]}" 0 0 |
All needed Apache modules are installed but koha-plack tells me: WARNING: koha-plack requires some Apache modules that you are missing. You can install them with: sudo a2enmod headers proxy_http This really is not true. What happened? There is a syntax error in one of my local sed changes in a config file. Looking a bit deeper, I see this test in sub check_env_and_warn() if ! /usr/sbin/apachectl -M 2> /dev/null | grep -q ${module}; then missing_modules="${missing_modules}${module} " fi Altough the grep -q part looked mysterious to me at first, the problem seems to be the pipe. If the first process exits with an error, the second will have an error too on the closed handles.