Guide to installing Wordpress on Mac


Install MySQL, NginX with PHP-FPM

Download latest wordpress


Then unzip the package using:

tar -xzvf latest.tar.gz 

WordPress package will be extractec into a folder called wordpress inside of tar.gz package parent directory.

Configure nginx

NOTE: Update with appropriate dev domain.

Update nginx /opt/local/etc/nginx/sites-available/

server {
  listen 80;

  root /Users/Marek/Workspace/Innocentio/;
  index               index.php index.html index.htm;

  location ~ \.php$ {
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $document_root/$fastcgi_script_name;

  error_page  404              /404.html;
  error_page  500 502 503 504  /50x.html;

Remember to symlink

cd /opt/local/etc/nginx/sites-enabled/
sudo ln -s ../sites-available/ ./

Update /etc/hosts



Create MySQL database and user for wordpress

Launch mysql CLI

mysql -u root -p
create database wordpress;
create user wordpress;
grant all on wordpress.* to 'wordpress'@'localhost' identified by 'wp_password';
flush privileges;

Post-install configuration

Install updates and plugins without ftp

Add bellow lines to wp-config.php:

/* enables updates and plugin installation without ftp */
define('FS_METHOD', 'direct');

Cd to your wordpress directory and set write privileges for wp-content and wp-content/plugins:

chmod 777 wp-content/
chmod 777 wp-content/plugins
chmod 777 wp-content/themes

*Note: * It is safer to reverse privileges back to original after you have finished plugin installation.

Published by IndieForger