On this post, I'll be explaining as granular as possible how to configure an Ubuntu Server so you can run Drupal 7 or Drupal 8 or Drupal 9 sites or any PHP application on your local environment for development. We'll be using Ubuntu 18.04 which is the latest release until the date of this post and the php/apache packages provided by the distro and it will provide PHP 7.2 packages that are recommended for Drupal development.
This post is targeted for Apache Server only, which i think is the most robust web server for Drupal but overall the best option to run PHP applications natively. You can read more on the following links how to configure Drupal for other web servers or configurations such as Nginx if you are interested.
Let's start by getting the required packages:
Another good option to run Drupal sites nowadays is Nginx. Nginx is a Proxy/Web Server not as complex as Apache and is well known for is security, responsiveness and speed when handling PHP apps together with PHP-FMP. On this this post I will introduce you on how to manually install and run Nginx and PHP-FPM so you can host any Drupal site with SSL support.
The suggested installation instructions by drupal.org: https://www.drupal.org/node/2310819
Perusio Nginx suggested Drupal Configuration https://github.com/perusio/drupal-with-nginx/tree/D7#installation…
The reason for this blog is to create a guide on how to install Drupal on a Linux Server ( I choose Ubuntu 10.04 amd64 LTS but any Linux distro will work just fine) but instead of using all the PHP packages bundled with this Linux distribution we will be using Zend Server which is an Application Sever built for PHP by Zend.
So, once you have set up Ubuntu, let's login as the root user typing the following command:
$ sudo -s
cool , now that we have all the privileges, let's add the Zend Server repository to our sources list by typing:
# nano /etc/apt/sources.list
at the end of the file add the following lines:
deb http://repos.zend.com/zend-server/deb server non-free
save and exit.
Once we added the repository we also need to add the public key for it, we do…Read more...