[varnish] Add HSTS header on redirect
This commit is contained in:
parent
7458430485
commit
813c273e68
1 changed files with 1 additions and 0 deletions
|
@ -47,6 +47,7 @@ sub vcl_synth {
|
||||||
# Execute TLS or www. redirect
|
# Execute TLS or www. redirect
|
||||||
if (resp.status == 750) {
|
if (resp.status == 750) {
|
||||||
set resp.http.Location = "https://www.tazj.in" + req.url;
|
set resp.http.Location = "https://www.tazj.in" + req.url;
|
||||||
|
set resp.http.Strict-Transport-Security = "max-age=31536000;includeSubdomains;preload";
|
||||||
set resp.status = 301;
|
set resp.status = 301;
|
||||||
return (deliver);
|
return (deliver);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue