Skip to content

Conversation

@jefft
Copy link
Contributor

@jefft jefft commented Jan 20, 2024

When setting up Jethro, if conf.php exists but is not readable by the runtime PHP user, the browser returns a generic 500 error:

image

and in the Apache error log we get this (incorrect) error message:

[Sat Jan 20 16:15:10.546667 2024] [proxy_fcgi:error] [pid 1746389:tid 140317700662848] [remote 100.94.18.157:48972] AH01071: Got error 'PHP message: PHP Fatal error: Jethro configuration file not found. You need to copy conf.php.sample to conf.php and edit it before Jethro can run in /home/jethro/code/2.34.1/app/index.php on line 32'

The attached patch to index.php improves error messages so that both the web browser and Apache logs see the message, and

  • if conf.php does not exist, the user sees:
    Jethro configuration file not found. You need to copy /home/jethro/code/2.34.1/app/conf.php.sample to /home/jethro/code/2.34.1/app/conf.php and edit it before Jethro can run
  • if conf.php exists but is not readable, the runtime user is mentioned in the error message:
    /home/jethro/code/2.34.1/app/conf.php not readable by user www-data.

@tbar0970 tbar0970 merged commit 42f644f into tbar0970:master May 6, 2024
@jefft jefft deleted the improve-setup-errmsg branch November 15, 2024 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants