How do I use VMs in Webmin / Virtualmin, could I create subdomains on the VM instead of Cloudflare?

SYSTEM INFORMATION
OS type and version Almalinux 9.8
Webmin version 2.670

Sharing knowledge about this topic and appreciating any suggestions:

LOVABLE:
How do I use VMs in Webmin / Virtualmin, could I create the subdomains on the VM instead of Cloudflare?

No, unless your VM is the one handling the domain’s DNS.

Why: the internet only reads DNS records from the server that is authoritative for the domain. Today, the nameservers for domain are Cloudflare’s. If you create the subdomain in Virtualmin (in the VM’s BIND), no one will query that server, and the verification will never complete.

Your options:

Keep it on Cloudflare (recommended): create the two NS records for notify (for ns3.lovable.cloud and ns4.lovable.cloud) and the TXT _lovable-email there, with the gray cloud (“DNS only”).

Move the DNS to the VM: change the domain’s nameservers at registro.br to your VM’s. Before doing so, recreate in Virtualmin all the records that are currently on Cloudflare (site, email MX, etc.). Otherwise, the site and emails will stop working. This is more work and has higher risk.

Attention: even if the DNS goes to the VM, the notify can’t be a “Virtual Server” (a website or mailbox) in Virtualmin. It needs to be just an NS delegation to Lovable, because Lovable handles the sending records for this subdomain. The other subdomains can stay on the VM normally.

You can follow the verification in Cloud → Emails.