Thứ Ba, 29 tháng 11, 2016

[Tutorial] How to install Drupal 8.2.3 on macOS Sierra?

Step 1: Description and Install MAMP


MAMP is a solution stack composed of free and open-source and proprietary commercial software used together to run dynamic web sites on Apple Macintosh computers. MAMP is an acronym of macOS, the operating system; Apache, the web server; MySQL, the database management system; and PHP, Perl, or Python, all programming languages used for web development.

Though originally only Apache was integrated into Mac OS X, MAMP has become popular because it is free and because of the ubiquity of its components, and Mac OS X 10.5 and above ships with PHP and is MySQL-ready. When used in combination it supports application servers. MAMP may also be used with popular CMS programs like Drupal for setting up a local development environment.


- Download the MAMP as a local server. It is suitable for a Mac - MAMP (My opinion).
- Install the MAMP and leave the settings as default. Everything will be available on the http://localhost:8888 address.

Step 2: Config

Config php.ini file

- Go to /Applications/MAMP/bin/php/php7.0.12/conf/php.ini
- Open php.ini with the TextEdit app.
- Scroll down to the [OPcache] section which is at the end of the document
- You'll see a line below the [OPcache] which is starting with a “;” (semi-colon)
- Save it and restart MAPP

Config httpd.conf file

- Go to /Applications/MAMP/conf/apache/httpd.conf
- Open with the TextEdit app
- Scroll down approximately at the half of the file when you'll see the .htaccess details (line 239)
- Here change the line “AllowOverride None” to “AllowOverride All” and remove the number sign "#" if it's there before the AllowOverride line.
- Save it.

Step 3: Install Drupal

- Download the Drupal 8.2.3 at here
- Extract the file
- Go to drupal-8.2.3/sites/default
- Make a copy the file default.settings.php and rename it to settings.php
- Hold down the command button and mark the files folder and settings.php and then right click one of them and click on the Get info option.
- Open down the Sharing & Permissions part and set the Privilege Read & Write for both of the them.
- After all these copy the folder drupal-8.2.3 to /Applications/MAMP/htdocs
- Make sure to create a MySQL table for your drupal at the http://localhost:8888/phpmyadmin (Username: root, Password: root)
- Open up your browser and go to http://localhost:8888/drupal-8.2.3 and you'll see the drupal installation.
Step 1: Choose language

Step 2: Select an installation profile

   Step 3: Database configuration (Database username: root; Database password: root)

Step 4: Installing …

Step 5: Configure site

   Step 6: Install complete