A
A
Alexander Bondarenko2020-07-15 11:48:40
PHP
Alexander Bondarenko, 2020-07-15 11:48:40

How to properly install php on debian server?

Installed php on the server, uploaded it to django static files, but I get an error

Failed to load resource: the server responded with a status of 404 (Not Found)

although the file is on the server, and I did collectstatic
Installed like this
sudo apt update
sudo apt install php php-fpm
обновил код nginx
server {

    # . . . other code

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/run/php/php7.3-fpm.sock;
    }
}
sudo systemctl restart nginx

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Gornostaev, 2020-07-15
@bond_1013

Statics are statics , not scripts in another language.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question