# Add PHP 7.3 PPA
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
# Install PHP 7.3 with basic modules
sudo apt-get install php7.3 php7.3-cli php7.3-common php-pear php7.3-curl php7.3-dev php7.3-gd php7.3-mbstring php7.3-zip php7.3-mysql php7.3-xml php7.3-fpm libapache2-mod-php7.3 php7.3-imagick php7.3-recode php7.3-tidy php7.3-xmlrpc php7.3-intl
# Search specific packages
sudo apt-cache search php7.3
# Or, if you want to check all the PHP modules available in Ubuntu, run:
apt-cache search --names-only ^php
# Change the PHP version - To set PHP 7.0 as the default, run:
update-alternatives --set php /usr/bin/php7.0
# To set PHP 7.2 as the default, run:
update-alternatives --set php /usr/bin/php7.2
# To set PHP 7.3 as the default, run:
update-alternatives --set php /usr/bin/php7.3
# Now change php-fpm socket path in nginx config and restart php-fpm
sudo service php7.3-fpm restart
# Restart nginx
sudo service nginx restart
Last active
January 4, 2020 07:30
-
-
Save 247software-sanket-gandhi/c67370db9d3be155defdfb52ec202dbd to your computer and use it in GitHub Desktop.
Ubuntu 16.04 - Install PHP 7.3, PHP-FPM 7.3
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment