/ wa.fo wip
This commit is contained in:
@@ -2,13 +2,16 @@
|
|||||||
# configuration of wa.fo / frode klevstul / oct 2025
|
# configuration of wa.fo / frode klevstul / oct 2025
|
||||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
|
|
||||||
# sc.op.fo ➔ wa.fo
|
# <<<<< REDIRECTS OF OTHER DOMAINS >>>>>
|
||||||
|
|
||||||
|
# sc.op.fo ➔ wa.fo (http)
|
||||||
server {
|
server {
|
||||||
listen 80;
|
listen 80;
|
||||||
server_name sc.op.fo;
|
server_name sc.op.fo;
|
||||||
return 301 https://wa.fo$request_uri;
|
return 301 https://wa.fo$request_uri;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# sc.op.fo ➔ wa.fo (https)
|
||||||
server {
|
server {
|
||||||
listen 443 ssl;
|
listen 443 ssl;
|
||||||
listen [::]:443 ssl;
|
listen [::]:443 ssl;
|
||||||
@@ -22,6 +25,31 @@ server {
|
|||||||
return 301 https://wa.fo$request_uri;
|
return 301 https://wa.fo$request_uri;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# <<<<< SETUP OF MAIN DOMAIN >>>>>
|
||||||
|
|
||||||
|
# enforce ssl and bare domain (http)
|
||||||
|
# ($server_name will return the first value given)
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name op.fo www.op.fo;
|
||||||
|
return 301 https://$server_name$request_uri;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# * ➔ bare domain (https)
|
||||||
|
server {
|
||||||
|
listen 443 ssl http2;
|
||||||
|
listen [::]:443 ssl http2;
|
||||||
|
|
||||||
|
ssl_certificate /etc/nginx/acme.sh/wa.fo/fullchain.pem;
|
||||||
|
ssl_certificate_key /etc/nginx/acme.sh/wa.fo/key.pem;
|
||||||
|
ssl_trusted_certificate /etc/nginx/acme.sh/wa.fo/cert.pem;
|
||||||
|
|
||||||
|
server_name *.wa.fo;
|
||||||
|
return 301 $scheme://$host$request_uri;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
# http to https
|
# http to https
|
||||||
server {
|
server {
|
||||||
listen 80;
|
listen 80;
|
||||||
|
|||||||
Reference in New Issue
Block a user