Fork me on GitHub

Mac下安装nginx

Mac安装nginx

安装brew(由于MAC自带ruby,所以安装起来很方便)

1
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

安装后命令存在 /usr/local/bin/brew

brew安装nginx

1
brew install nginx   (或者 /usr/local/bin/brew install nginx)

过后等着就行了。会自动安装pcre和ssl等。