Nginx Php Mysql For Mac



  1. Nginx Php Mysql For Mac Os
  2. Nginx Php Mysql For Mac Download
  3. Nginx Php Mysql For Mac Installer
  4. Nginx Php Mysql Ubuntu
  5. Install Nginx Php Mysql Mac Os X

Perfect time to get rid of the LAMP (Linux Apache MySQL PHP) web server stack and replace it with Nginx and PHP-FPM. Below you can read a detailed guide how to setup Nginx, PHP-FPM, MySQL and phpMyAdmin on OS X 10.9 / Mavericks. Updated for Yosemite users: Updated the guide for OS X 10.10 since Yosemite is officially released. The free web development solution with Apache, Nginx, PHP & MySQL What is MAMP? MAMP installs a local server environment in a matter of seconds on your Windows or macOS computer. Install Windows 10 WSL for Nginx + php. If you don’t have Windows 10 WSL (Windows Subsystem.

1 Install homebrew

Run this command to install homebrew at system level

1.1 Homebrew libs

Nginx Php Mysql For Mac

Run bellow command and check if have any thing need to be fixed.

2 Install nginx

Command to install nginx via brew.

3 Install PHP 5.6

3.1 Install PHP

To install PHP v 5.6.x (script is from http://php-osx.liip.ch)

3.2 Enable new PHP 5.6 at system

Enter:

Disable apple builtin old php-fpm version

Create symlink for new version of php-fpm

3.3 Install composer

Maybe need to update .bash_profile to add new line

3.4 Configuration file

php.ini : /usr/local/php5/lib/php.iniphp-fpm.conf: /usr/local/php5/etc/php-fpm.confnginx : /usr/local/etc/nginx/nginx.conf

3.4.1 Config php.ini

Find and set this:

3.4.2 Config php-fpm

Find and set these:

  • pid file, this file is auto created by php-fpm every start to save it's process id. We will use this pid to kill php-fpm running instance in script 3.5 bellow
  • if you want to change listen port for php-fpm, (default 9001), you also should check it.

Nginx Php Mysql For Mac Os

Nginx php windows

3.5 Create .sh file to run webserver via command

Create file webserver.sh at your user folder: ~/webserver.sh

Add below content into webserver.sh file

Save it.From now, you can start/restart server by run this command:

Nginx Php Mysql For Mac Download

3.6 NGINX support OpenSSL self-signed

Command to generate SSL certificate via OpenSSL for Nginx

Update nginx config file for ssl

4 Upgrade Ruby

Nginx Php Mysql For Mac Installer

4.1 Using RVM to manage and upgrade Ruby RVM

After installed rvm

Check for rmv load script

4.2 Install Ruby and set default version

RVM will auto install Ruby newest stable version to system

5 CocoaPods

6 MySQL 5.7.x

6.1 Install MySQL

  • Download MySQL at (http://dev.mysql.com/downloads/mysql/), you can download DMG file for easy install.
  • After installed, the root/password will be shown. Note it to use later
  • Add mysql bin folder to terminal PATH env by edit file ~/.bash_profile
Mysql

Enter this information, then save it and restart terminal.

  • Let's change the default expired password by using this command:

Nginx Php Mysql Ubuntu

6.2 Install phpMyAdmin

  • Go to: https://www.phpmyadmin.net
  • Download the lastest release and unzip to http root directory
  • Login to phpMyAdmin by user/password above in step 6.1

7 Postfix to sendmail

Mac OS X has shipped with postfix to send email via PHPSendmail. But default, postfix is not started.

Install Nginx Php Mysql Mac Os X

Add this lines to bottom of file ~/webserver.sh. Postfix mail server will start at time of start webserver.