Yosemite Rapid construction of PHP5.6 development environment

Source: Internet
Author: User
Tags install brew

1, installation homebrew

Ruby-e "$ (curl-fssl https://raw.github.com/mxcl/homebrew/go/install)"

2, Installation Homebrew-cask

Brew tap Phinze/homebrew-cask && Brew Install Brew-cask

3. Install Oh-my-zsh & Iterm2 & Lanch rocket

4. Install Common development components

Brew install wget watch Tmux cmake OpenSSL imagemagick graphicsmagick readline autoconf multitail source-highlight Autojum P Zsh-completions composer

5. Pre-installed PHP

Brew tap Homebrew/dupes && Brew tap homebrew/versions && Brew Tap homebrew/homebrew-php

6. Install PHP

Brew Options php56 && Brew Install php56

7, install common PHP expansion pack

Brew Install Php56-xdebug php56-mcrypt Php56-redis Php56-mongo Php56-imagick

8. Open the system's own Apache and enable the freshly brew-installed PHP

sudo vi/private/etc/apache2/httpd.conf

9, find "#LoadModule php5_module libexec/apache2/libphp5.so" line, insert a row below

LoadModule php5_module/usr/local/cellar/php56/5.6.5/libexec/apache2/libphp5.so

10. Restart the system with Apache

sudo apachectl restart

You can then add a index.php to the Apache Wwwroot (which is probably the/library/webserver/documents directory) and output a phpinfo () look.

If you need to install MySQL, you can turn off the current terminal, and then open the ITerm2 you just installed, enter the following command:

Brew Install MySQL

After the installation is complete, enter the following command:

Mysql_secure_installation

After the carriage return, follow the prompts to configure the basic security options for MySQL in one step.

All reboots, set to boot can use the launch rocket installed above, the effect is as shown:

Yosemite Rapid construction of PHP5.6 development environment

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.