I currently have an nginx server which can be accessed by typing in domain.com both by HTTP and HTTPS. However when I attempt to connect by typing www.domain.com instead it seems that the connection will hang and Firefox reports "The connection to the server was reset while the page was loading.."
Here is my current server_name config:
server_name localhost www.example.com example.com;
The nginx documentation seems to suggest that this should work, what am I doing wrong?