- MacOS
brew install nginx && nginx -v
nginx -V
👉 /opt/homebrew/etc/nginx/nginx.conf
cat nginx.conf > /opt/homebrew/etc/nginx/nginx.conf
mkdir nginx-certs &&
cd nginx-certs &&
openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout nginx-selfsigned.key -out nginx-selfsigned.crt
Enter some basic information of the certificate that promted
nginx
nginx -h
nginx -s reload
nginx -s stop
tail -f /usr/local/var/log/nginx/access.log
nginx -s reload
mkdir ~/nginx-certs
cd ~/nginx-certs
openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout nginx-selfsigned.key -out nginx-selfsigned.crt