Add host name check in nginx conf
This commit is contained in:
parent
9108c7ea1a
commit
cf4a1e5ec7
@ -19,6 +19,10 @@ server {
|
||||
listen [::]:443 ssl http2;
|
||||
server_name ptcoffee.com www.ptcoffee.com;
|
||||
|
||||
if ($http_host !~* ^(ptcoffee.com|www.ptcoffee.com)$ ) {
|
||||
return 444;
|
||||
}
|
||||
|
||||
# SSL
|
||||
ssl_certificate /etc/letsencrypt/live/ptcoffee.com/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/ptcoffee.com/privkey.pem;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user