I have it setup so that non-www requests redirect to www, however when I link the domain, say, in Discord with https://my-domain.com or if I type it out in the browser like that it doesn't work, it says This site can't be reached. Is there any way I can fix that?
This is the block I have in my /etc/nginx/sites-enabled/default file to redirect www requests
server {
server_name www.my-domain.com;
return 301 $scheme://my-domain.com$request_uri;
}