you can follow these steps:
- Update the package manager by running the following command:
sudo yum update
- Enable the Remi repository by installing the
sudo amazon-linux-extras install epel
sudo amazon-linux-extras enable php8.0
- Install PHP 8.0 and its dependencies by running the following command:
sudo yum install php php-devel php-mysqlnd php-opcache php-xml php-mbstring php-json
- Verify that PHP 8.0 is installed by running the following command:
This should display the version of PHP installed on your system.
Note: If you encounter any issues during the installation, you can refer to the official documentation for Amazon Linux 2 or the Remi repository for more information.