Install Brew on Mac and nginx through brew

Source: Internet
Author: User
Tags install brew
: This article mainly introduces how to install Brew on Mac and how to install nginx through brew. if you are interested in the PHP Tutorial, refer to it.
  • Install Brew on Mac

The installation command is as follows:
Curl-LsSf http ://Github. Com/mxcl/homebrew/tarball/master | sudo tar xvz-C/usr/local -- strip 1
After brew is installed successfully, you can install the software you want, for example, wget. the command is as follows:
Sudo brew install wget
To uninstall the SDK, run the following command:
Sudo brew uninstall wget
Run the following command to view and install the software:
Sudo brew search/apache */

  • Install nginx on mac

1. brew search nginx

2. brew install nginx

Start nginx and sudo nginx; access localhost: 8080 and find that the nginx welcome page has appeared.
Note: make a soft connection between ln-s/usr/local/sbin/nginx/usr/bin/nginx.
Common commands include:
View nginx-V version and configuration file address
View nginx-v version
Nginx-c filename specifies the configuration file
Nginx-h help

# Reload configuration | restart | stop | exit nginx

Nginx-s reload | reopen | stop | quit

# Enable nginx

Sudo nginx

# Test whether the configuration has syntax errors

Nginx-t

In addition, the following command is attached to install brew on Mac:

The installation command is as follows:
Curl-LsSf http ://Github. Com/mxcl/homebrew/tarball/master | sudo tar xvz-C/usr/local -- strip 1
After brew is installed successfully, you can install the software you want, for example, wget. the command is as follows:
Sudo brew install wget
To uninstall the SDK, run the following command:
Sudo brew uninstall wget
Run the following command to view and install the software:
Sudo brew search/apache */
Note/apache */is usedRegular expression, Separated.

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.