Find values of suPHP variables (ie. ${HOME}, ${USERNAME}, ${GROUPNAME}…)

StackOverflow https://stackoverflow.com/questions/8040022

  •  23-02-2021
  •  | 
  •  

سؤال

I keep getting 500 (Internal Server Error) and I suspect this is because I am setting docroot to docroot=${HOME}*. I want to 'peek under the hood' because I suspect ${HOME} is what is causing the problems. How can I do this, or at least write all the variables to log whenever there is a problem.

EDIT I am using suPHP version 0.7.1-1 which does support variables within docroot

EDIT I tried cheating by appending the ${HOME} variable to the log file name. For simplicity, I used the ${UID} variable since ${HOME} might have forward slashes in it. I updated the below line in the /etc/suphp/suphp.conf file

logfile=/var/log/suphp/suphp${UID}.log

I get the following file

/var/log/suphp/suphp${UID}.log

It's as if the ${UID} variable does not even exist.

هل كانت مفيدة؟

المحلول

This problem arises out of the fact that the * pattern in regular expressions here does not match /. Furthermore, the * is not even necessary since docroot will automatically include all recursive files. All I had to do was change

docroot=${HOME}*

to

docroot=${HOME}
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top