Couldn't find any package by glob 'php8.0' in debian

Viewed 21103

hi am using a Kali linux Rolling 2020.4 last update and every thing is okay from 2 years until now after i add the PPA of php and update every thing for last update when i run

sudo apt install php8.0

i get error

E: Unable to locate package php8.0
E: Couldn't find any package by glob 'php8.0'

but i dont know what's the problem here's the ppa and have php8

http://ppa.launchpad.net/ondrej/php/ubuntu/pool/main/p/php8.0/

and here too

http://ppa.launchpad.net/ondrej/php/ubuntu/

the following command is was i used

sysadmin@debian-10:~$ sudo apt install -y lsb-release apt-transport-https ca-certificates wget
sysadmin@debian-10:~$ sudo wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg
sysadmin@debian-10:~$ echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/php.list
2 Answers

Install PHP 8 on Debian

For Debian Buster (10) and Debian Bullseye (11)

With root access:

apt update && apt install -y wget gnupg2 lsb-release
wget https://packages.sury.org/php/apt.gpg && apt-key add apt.gpg
echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" | tee /etc/apt/sources.list.d/php.list
apt update && apt install -y php8.1
php -v # Outputs "PHP 8.1.3 ..."

This doesn't works for:

Install PHP 8.1 on Ubuntu

sudo apt update && apt install -y software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt update && sudo apt install -y php8.1
php -v # Outputs "PHP 8.1.3 ..."

Ubuntu 21.04 has reached its end of life in January 2022, and ondrej/php does not support any EOL version. You need to upgrade your Ubuntu version first to be able to use this repository again

Related