GithubHelp home page GithubHelp logo

my-homebrew's Introduction

Homebrew (E)Nginx MySQL PHP Installer

Native way to setup web environment for Mac.

Overview

This script will install and setup Nginx + MySQL + PHP + Redis + Composer + Drush through Homebrew.

Requirements

Installation

curl -L https://raw.github.com/Happensit/My-homebrew/master/install.sh | bash

Usage

getlooky [start | stop]

Creating VirtualHost

For example let's create virtual host for Drupal 'customsite'.

Copy Drupal preset: cp /usr/local/etc/nginx/sites-available/drupal.dev /usr/local/etc/nginx/sites-available/customsite.dev

Change name and path to site: vim /usr/local/etc/nginx/sites-available/customsite.dev

server {
  listen       80;
  server_name  mysite.local;
  root /Users/Happensit/Sites/customsite;

  access_log /usr/local/var/log/nginx/customsite.access.log;
  error_log  /usr/local/var/log/nginx/customsite.error.log;

  include /usr/local/etc/nginx/common/drupal;
}

Enable virtual host: ln -s /usr/local/etc/nginx/sites-available/mysite.dev /usr/local/etc/nginx/sites-enabled/customsite.dev

Add 127.0.0.1 customsite.dev to /etc/hosts.

Enable Xhprof with Drupal 7

drush dl devel
drush en devel
drush vset devel_xhprof_directory "/usr/local/Cellar/php56-xhprof/254eb24"
drush vset devel_xhprof_url "http://xhprof.dev"
drush vset devel_xhprof_enabled 1

Default Settings

MySQL

Username: root

Password:

Port: 3306

Xdebug

Remote port is 9002

Configs

Nginx: /usr/local/etc/nginx/nginx.conf

FastCGI: /usr/local/etc/nginx/fastcgi.conf

PHP: /usr/local/etc/php/5.6/php.ini

Redis: /usr/local/etc/redis.conf

Xdebug: /usr/local/etc/php/5.6/conf.d/ext-xdebug.ini

xhprof: /usr/local/etc/php/5.6/conf.d/ext-xhprof.ini

Source code: /usr/local/Cellar/php56-xhprof/

MySQL: /usr/local/etc/my.cnf

my-homebrew's People

Contributors

happensit avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.