If you want to start NGINX on system bootup you can use Homebrew‘s handy service command.
- Step 1: Install NGINX via homebrew – if not already installed.
- Step 2: Add NGINX as an autostart service –
sudo brew services start nginx.
brew install nginx sudo brew services start nginx
After NGINX is added to the autostart, you can disable its autostart using the following command:
sudo brew services stop nginx