0

i'm trying to configure my 3rd webapp on my raspberry. I accidently pulled a nginx conf for this third site containing following lines:

[...]
server {
  [...]
  location ~.php$ {
    [...]
    fastcgi_param PHP_ADMIN_VALUE      "open_basedir=$base/:/usr/lib/php/:/tmp/";
    [...]
  }
}

From now on, even my two other apps are complaining with following line:

2020/05/06 21:39:55 [error] 21359#21359: *35 FastCGI sent in stderr: "PHP message: PHP Warning:  file_exists(): open_basedir restriction in effect. File(/var/www/<1ST_WEBAPP_ROOT>/lib/composer/autoload.php) is not within the allowed path(s): (/var/www/<3RD_WEBAPP_ROOT>/:/usr/lib/php/:/tmp/) in /var/www/<1ST_WEBAPP_ROOT>/lib/base.php on line 504" while reading response header from upstream, client: <IP>, server: <1ST_WEBAPP_URL>, request: "GET /status.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php/php7.3-fpm.sock:", host: "<1ST_WEBAPP_URL>"

I uncommented this line:

[...]
server {
  [...]
  location ~.php$ {
    [...]
    #fastcgi_param PHP_ADMIN_VALUE      "open_basedir=$base/:/usr/lib/php/:/tmp/";
    [...]
  }
}

stoped, restarted nginx

sudo systemctl stop nginx
sudo systemctl restart nginx

But the error persists. Even removing both server blocks (port 80 and 443) didn't help. Any suggestions what i'm doing wrong?

1 Answer 1

1

Found it...

Last step missing was restarting the php-fpm

sudo /etc/init.d/php7.3-fpm restart

Thank you for reading. Sorry

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .