If you didn’t add a DNS name when you created the VM, that needs to be set.
And remember when you create a VM there are a bunch of other objects which get created with it. One of those will stop you accessing the VM from the Internet.
Need more? Here’s the solution.