This is a guide on how to point a domain to your VM to serve content with your VM as the host.
You require a DNS server to be set up for you. Usually, most domain provider has that already set up, and you can start pointing. But for this guide, we will be using Cloudflare. Cloudflare offers free DNS service and Wildcard SSL, which is unbelievable.
Head to Cloudflare to login to your account or signup here: https://dash.cloudflare.com/sign-up if you haven't already.
Click add site on the top right of your Cloudflare account
Add your domain and click add site
Choose the free plan
Cloudflare will check your existing DNS record and will request you to check and update your DNS record
You have to add A record to tell Cloudflare to point the domain name to your VM IP
Remember to enable the proxy setting, which helps you hide your VM IP to prevent exposing your VM IP, leading to potential DDoS.
Also don't forget to clear any existing duplicate A record and CNAME you have to prevent any potential issues.
Remember to also add a Cname record to make sure www.yourdomainname.com will resolve
Click save and Continue
Now you have to change your domain's nameserver record to Cloudflare's nameserver.
When you are done, click Done, check the nameservers, and you are done pointing your domain to your VM.
Now try visiting your domain on your browser, and the domain will resolve!
Configuring SSL usually takes a lot of work and quite complicated.
With cloudflare, simply go to SSL/TLS tab and click on Flexible
With this your website will have a padlock beside the URL and it will be secured, to check, head to https://yourdomainname
Don't forget to enable Automatic HTTPS Rewrites after that so all HTTP traffic will be forwarded to HTTPS traffic.
You can do that by going to Cloudflare > SSL/TLS > Edge Certificates > Automatic HTTPS Rewrites > On
Haven't deployed a VM with Evoxt yet? Deploy a VM now!