Nginx - Redirect to https

Kenneth
Kenneth Author of holmq.dk
Image Author: https://commons.wikimedia.org/wiki/File:Nginx_logo.svg

Insert this code into your Nginx server {} block

>
1
2
3
4
5
server {
	listen 80;
	server_name YOURDOMAIN.com;
	return 301 https://$host$request_uri;
}

comments powered by Disqus
Copyright © 2019 Holmq.dk
Jekyll Bootstrap Theme: Mediumish