28 lines
853 B
Plaintext
28 lines
853 B
Plaintext
server {
|
|
listen 80;
|
|
server_name portfolio.example.com www.portfolio.example.com;
|
|
|
|
root /var/www/marcus;
|
|
index index.html;
|
|
|
|
location / {
|
|
try_files $uri $uri/ =404;
|
|
}
|
|
|
|
# Uncomment to redirect all HTTP to HTTPS if you provision certs separately:
|
|
# return 301 https://$host$request_uri;
|
|
}
|
|
|
|
# Example HTTPS block (use certbot or your CA to populate cert paths):
|
|
# server {
|
|
# listen 443 ssl http2;
|
|
# server_name portfolio.example.com;
|
|
# root /var/www/marcus;
|
|
# index index.html;
|
|
# ssl_certificate /etc/letsencrypt/live/portfolio.example.com/fullchain.pem;
|
|
# ssl_certificate_key /etc/letsencrypt/live/portfolio.example.com/privkey.pem;
|
|
# include /etc/letsencrypt/options-ssl-nginx.conf;
|
|
# ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
|
# location / { try_files $uri $uri/ =404; }
|
|
# }
|