> brew info nginx
nginx: stable 1.19.3 (bottled), HEAD
HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server
https://nginx.org/
/usr/local/Cellar/nginx/1.19.3 (25 files, 2.2MB) *
Poured from bottle on 2021-02-02 at 16:51:57
From: https://mirrors.aliyun.com/homebrew/homebrew-core.git/Formula/nginx.rb
License: BSD-2-Clause
==> Dependencies
Required: [email protected] ✔, pcre ✔
==> Options
--HEAD
Install HEAD version
==> Caveats
Docroot is: /usr/local/var/www
The default port has been set in /usr/local/etc/nginx/nginx.conf to 8080 so that
nginx can run without sudo.
nginx will load all files in /usr/local/etc/nginx/servers/.
To have launchd start nginx now and restart at login:
brew services start nginx
Or, if you don't want/need a background service you can just run:
nginx
根目录: /usr/local/var/www
配置文件: /usr/local/etc/nginx/nginx.conf