mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Bump minimum PHP version to 8.2 (#16413)
This commit is contained in:
@ -30,9 +30,9 @@ use LibreNMS\Validator;
|
|||||||
|
|
||||||
class Php extends BaseValidation
|
class Php extends BaseValidation
|
||||||
{
|
{
|
||||||
const PHP_MIN_VERSION = '8.1';
|
const PHP_MIN_VERSION = '8.2';
|
||||||
const PHP_MIN_VERSION_DATE = 'September, 2022';
|
const PHP_MIN_VERSION_DATE = 'October, 2024';
|
||||||
const PHP_RECOMMENDED_VERSION = '8.1';
|
const PHP_RECOMMENDED_VERSION = '8.3';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Validate this module.
|
* Validate this module.
|
||||||
|
@ -27,6 +27,9 @@ Connect to the server command line and follow the instructions below.
|
|||||||
=== "Ubuntu 22.04"
|
=== "Ubuntu 22.04"
|
||||||
=== "NGINX"
|
=== "NGINX"
|
||||||
```
|
```
|
||||||
|
apt install software-properties-common
|
||||||
|
LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
|
||||||
|
apt update
|
||||||
apt install acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd unzip python3-pymysql python3-dotenv python3-redis python3-setuptools python3-psutil python3-systemd python3-pip whois traceroute
|
apt install acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd unzip python3-pymysql python3-dotenv python3-redis python3-setuptools python3-psutil python3-systemd python3-pip whois traceroute
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -35,7 +38,7 @@ Connect to the server command line and follow the instructions below.
|
|||||||
```
|
```
|
||||||
apt install software-properties-common
|
apt install software-properties-common
|
||||||
add-apt-repository universe
|
add-apt-repository universe
|
||||||
add-apt-repository ppa:ondrej/php
|
LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
|
||||||
apt update
|
apt update
|
||||||
apt install acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd unzip python3-pymysql python3-dotenv python3-redis python3-setuptools python3-systemd python3-pip whois traceroute
|
apt install acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd unzip python3-pymysql python3-dotenv python3-redis python3-setuptools python3-systemd python3-pip whois traceroute
|
||||||
```
|
```
|
||||||
@ -44,7 +47,7 @@ Connect to the server command line and follow the instructions below.
|
|||||||
```
|
```
|
||||||
apt install software-properties-common
|
apt install software-properties-common
|
||||||
add-apt-repository universe
|
add-apt-repository universe
|
||||||
add-apt-repository ppa:ondrej/php
|
LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php
|
||||||
apt update
|
apt update
|
||||||
apt install acl curl apache2 fping git graphviz imagemagick libapache2-mod-fcgid mariadb-client mariadb-server mtr-tiny nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd whois python3-pymysql python3-dotenv python3-redis python3-setuptools python3-systemd python3-pip unzip traceroute
|
apt install acl curl apache2 fping git graphviz imagemagick libapache2-mod-fcgid mariadb-client mariadb-server mtr-tiny nmap php-cli php-curl php-fpm php-gd php-gmp php-json php-mbstring php-mysql php-snmp php-xml php-zip rrdtool snmp snmpd whois python3-pymysql python3-dotenv python3-redis python3-setuptools python3-systemd python3-pip unzip traceroute
|
||||||
```
|
```
|
||||||
@ -55,7 +58,7 @@ Connect to the server command line and follow the instructions below.
|
|||||||
dnf -y install epel-release
|
dnf -y install epel-release
|
||||||
dnf -y install dnf-utils http://rpms.remirepo.net/enterprise/remi-release-8.rpm
|
dnf -y install dnf-utils http://rpms.remirepo.net/enterprise/remi-release-8.rpm
|
||||||
dnf module reset php
|
dnf module reset php
|
||||||
dnf module enable php:8.1
|
dnf module enable php:8.2
|
||||||
dnf install bash-completion cronie fping git ImageMagick mariadb-server mtr net-snmp net-snmp-utils nginx nmap php-fpm php-cli php-common php-curl php-gd php-gmp php-json php-mbstring php-process php-snmp php-xml php-zip php-mysqlnd python3 python3-PyMySQL python3-redis python3-memcached python3-pip python3-systemd rrdtool unzip
|
dnf install bash-completion cronie fping git ImageMagick mariadb-server mtr net-snmp net-snmp-utils nginx nmap php-fpm php-cli php-common php-curl php-gd php-gmp php-json php-mbstring php-process php-snmp php-xml php-zip php-mysqlnd python3 python3-PyMySQL python3-redis python3-memcached python3-pip python3-systemd rrdtool unzip
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -64,14 +67,14 @@ Connect to the server command line and follow the instructions below.
|
|||||||
dnf -y install epel-release
|
dnf -y install epel-release
|
||||||
dnf -y install dnf-utils http://rpms.remirepo.net/enterprise/remi-release-8.rpm
|
dnf -y install dnf-utils http://rpms.remirepo.net/enterprise/remi-release-8.rpm
|
||||||
dnf module reset php
|
dnf module reset php
|
||||||
dnf module enable php:remi-8.1
|
dnf module enable php:8.2
|
||||||
dnf install bash-completion cronie fping gcc git httpd ImageMagick mariadb-server mtr net-snmp net-snmp-utils nmap php-fpm php-cli php-common php-curl php-gd php-gmp php-json php-mbstring php-process php-snmp php-xml php-zip php-mysqlnd python3 python3-devel python3-PyMySQL python3-redis python3-memcached python3-pip python3-systemd rrdtool unzip
|
dnf install bash-completion cronie fping gcc git httpd ImageMagick mariadb-server mtr net-snmp net-snmp-utils nmap php-fpm php-cli php-common php-curl php-gd php-gmp php-json php-mbstring php-process php-snmp php-xml php-zip php-mysqlnd python3 python3-devel python3-PyMySQL python3-redis python3-memcached python3-pip python3-systemd rrdtool unzip
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "Debian 12"
|
=== "Debian 12"
|
||||||
=== "NGINX"
|
=== "NGINX"
|
||||||
```
|
```
|
||||||
apt install apt-transport-https lsb-release ca-certificates wget acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php8.2-cli php8.2-curl php8.2-fpm php8.2-gd php8.2-gmp php8.2-mbstring php8.2-mysql php8.2-snmp php8.2-xml php8.2-zip python3-dotenv python3-pymysql python3-redis python3-setuptools python3-systemd python3-pip rrdtool snmp snmpd unzip whois
|
apt install apt-transport-https lsb-release ca-certificates wget acl curl fping git graphviz imagemagick mariadb-client mariadb-server mtr-tiny nginx-full nmap php-cli php-curl php-fpm php-gd php-gmp php-mbstring php-mysql php-snmp php-xml php-zip python3-dotenv python3-pymysql python3-redis python3-setuptools python3-systemd python3-pip rrdtool snmp snmpd unzip whois
|
||||||
```
|
```
|
||||||
|
|
||||||
## Add librenms user
|
## Add librenms user
|
||||||
@ -124,14 +127,14 @@ Ensure date.timezone is set in php.ini to your preferred time zone.
|
|||||||
|
|
||||||
=== "Ubuntu 22.04"
|
=== "Ubuntu 22.04"
|
||||||
```bash
|
```bash
|
||||||
vi /etc/php/8.1/fpm/php.ini
|
vi /etc/php/8.3/fpm/php.ini
|
||||||
vi /etc/php/8.1/cli/php.ini
|
vi /etc/php/8.3/cli/php.ini
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "Ubuntu 20.04"
|
=== "Ubuntu 20.04"
|
||||||
```bash
|
```bash
|
||||||
vi /etc/php/8.1/fpm/php.ini
|
vi /etc/php/8.3/fpm/php.ini
|
||||||
vi /etc/php/8.1/cli/php.ini
|
vi /etc/php/8.3/cli/php.ini
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "CentOS 8"
|
=== "CentOS 8"
|
||||||
@ -217,14 +220,14 @@ exit
|
|||||||
|
|
||||||
=== "Ubuntu 22.04"
|
=== "Ubuntu 22.04"
|
||||||
```bash
|
```bash
|
||||||
cp /etc/php/8.1/fpm/pool.d/www.conf /etc/php/8.1/fpm/pool.d/librenms.conf
|
cp /etc/php/8.3/fpm/pool.d/www.conf /etc/php/8.3/fpm/pool.d/librenms.conf
|
||||||
vi /etc/php/8.1/fpm/pool.d/librenms.conf
|
vi /etc/php/8.3/fpm/pool.d/librenms.conf
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "Ubuntu 20.04"
|
=== "Ubuntu 20.04"
|
||||||
```bash
|
```bash
|
||||||
cp /etc/php/8.1/fpm/pool.d/www.conf /etc/php/8.1/fpm/pool.d/librenms.conf
|
cp /etc/php/8.3/fpm/pool.d/www.conf /etc/php/8.3/fpm/pool.d/librenms.conf
|
||||||
vi /etc/php/8.1/fpm/pool.d/librenms.conf
|
vi /etc/php/8.3/fpm/pool.d/librenms.conf
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "CentOS 8"
|
=== "CentOS 8"
|
||||||
@ -333,7 +336,7 @@ Feel free to tune the performance settings in librenms.conf to meet your needs.
|
|||||||
```bash
|
```bash
|
||||||
rm /etc/nginx/sites-enabled/default
|
rm /etc/nginx/sites-enabled/default
|
||||||
systemctl restart nginx
|
systemctl restart nginx
|
||||||
systemctl restart php8.1-fpm
|
systemctl restart php8.3-fpm
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "Ubuntu 20.04"
|
=== "Ubuntu 20.04"
|
||||||
@ -371,7 +374,7 @@ Feel free to tune the performance settings in librenms.conf to meet your needs.
|
|||||||
```bash
|
```bash
|
||||||
rm /etc/nginx/sites-enabled/default
|
rm /etc/nginx/sites-enabled/default
|
||||||
systemctl restart nginx
|
systemctl restart nginx
|
||||||
systemctl restart php8.1-fpm
|
systemctl restart php8.3-fpm
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "Apache"
|
=== "Apache"
|
||||||
@ -409,7 +412,7 @@ Feel free to tune the performance settings in librenms.conf to meet your needs.
|
|||||||
a2enmod proxy_fcgi setenvif rewrite
|
a2enmod proxy_fcgi setenvif rewrite
|
||||||
a2ensite librenms.conf
|
a2ensite librenms.conf
|
||||||
systemctl restart apache2
|
systemctl restart apache2
|
||||||
systemctl restart php8.1-fpm
|
systemctl restart php8.3-fpm
|
||||||
```
|
```
|
||||||
|
|
||||||
=== "CentOS 8"
|
=== "CentOS 8"
|
||||||
|
@ -107,7 +107,7 @@ extra:
|
|||||||
article_nav_top: false
|
article_nav_top: false
|
||||||
article_nav_bottom: true
|
article_nav_bottom: true
|
||||||
php:
|
php:
|
||||||
version_min: 8.1
|
version_min: 8.2
|
||||||
social:
|
social:
|
||||||
- icon: fontawesome/brands/github
|
- icon: fontawesome/brands/github
|
||||||
link: https://github.com/librenms/
|
link: https://github.com/librenms/
|
||||||
|
Reference in New Issue
Block a user