Updating PHP to the Latest Version
Process
- SSH into the Bastion
- SSH into one of the webservers
- Run:
sudo apt update - Run:
sudo apt search php - Find the version to install in the list
- Run:
sudo apt install %PHPVersion% - Run:
sudo apt install %PHPVersion%-mongodb %PHPVersion%-redis %PHPVersion%-gmagick %PHPVersion%-mbstring %PHPVersion%-mysql %PHPVersion%-xml %PHPVersion%-xmlrpc %PHPVersion%-gd %PHPVersion%-mcrypt %PHPVersion%-imagick %PHPVersion%-curl %PHPVersion%-dev %PHPVersion%-zip %PHPVersion%-opcache
Replace %PHPVersion% with the version number found in step 5 (e.g., php8.4).