Changes
Page history
Update PHP 8.1 migration info
authored
Dec 28, 2022
by
Marius David Wieschollek
Show whitespace changes
Inline
Side-by-side
Administrators/Guides/DietPi/Upgrade-to-PHP-8.0-with-Lighttpd.md
View page @
b3e4c46c
> **PHP 8.0 is so 2020. Why not update to PHP 8.1 right away?**
>
> **[Check out the PHP 8.1 upgrade guide](./Upgrade-to-PHP-8.1-with-Lighttpd)**
## Before you start
-
This tutorial was developed for and tested with DietPi 7.2 on a RaspberryPI.
-
This tutorial only works if you use "Lighttpd" as webserver.
...
...
@@ -65,30 +69,7 @@ with `CRTL` + `x` you can close the editor.
## Set up Lighttpd for PHP 8.0
Now you need to edit the configuration for lighttpd to instruct it to use PHP 8.0
Run
`nano /etc/lighttpd/conf-available/15-fastcgi-php.conf`
to open the configuration file.
It should have this section:
```
fastcgi.server += ( ".php" =>
((
"socket" => "/run/php/php7.3-fpm.sock",
"broken-scriptfilename" => "enable"
))
)
```
You need to change the "socket" from "/run/php/php7.3-fpm.sock" to "/run/php/php8.0-fpm.sock".
The section should now read like this:
```
fastcgi.server += ( ".php" =>
((
"socket" => "/run/php/php8.0-fpm.sock",
"broken-scriptfilename" => "enable"
))
)
```
Save the file and then run the following command to restart lighttpd:
Just restart lighttpd:
```
bash
service lighttpd force-reload
```
...
...
...
...