linux - install nginx
apt-get update
apt install nginx -y
check version info:
nginx -v
nginx -V
echo $HOSTNAME > /var/www/html/index.nginx-debian.html
curl localhost
nginx 配置文件:
/etc/nginx/sites-available/default
配置HTTPS
/etc/nginx/sites-available/default
listen 443 default_server ssl;
ssl_certificate /etc/nginx/sites-available/cert.pem;
ssl_certificate_key /etc/nginx/sites-available/privkey.pem;
service nginx restart