在 Azure 门户中为 Linux VM 创建完全限定的域名Create a fully qualified domain name in the Azure portal for a Linux VM

Azure 门户中创建虚拟机 (VM) 时,此门户会自动为虚拟机创建公共 IP 资源。When you create a virtual machine (VM) in the Azure portal, a public IP resource for the virtual machine is automatically created. 可以使用此 IP 地址远程访问 VM。You use this IP address to remotely access the VM. 虽然此门户不会创建完全限定的域名 (FQDN),但可以在创建 VM 后添加完全限定的域名。Although the portal does not create a fully qualified domain name, or FQDN, you can add one once the VM is created. 本文演示了创建 DNS 名称或 FQDN 的步骤。This article demonstrates the steps to create a DNS name or FQDN.

创建 FQDNCreate a FQDN

阅读本文的前提是已创建 VM。This article assumes that you have already created a VM. 如果需要,可以在门户中创建 LinuxWindows VM。If needed, you can create a Linux or Windows VM in the portal. 在 VM 正常运行后,请按照以下步骤操作:Follow these steps once your VM is up and running:

  1. 在门户中选择 VM。Select your VM in the portal. 在“DNS 名称”下选择“配置” 。Under DNS name, select Configure.
  2. 输入 DNS 名称,然后在页面顶部选择“保存”。Enter the DNS name and then select Save at the top of the page.
  3. 若要返回 VM 概述边栏选项卡,请选择右上角的 X 以关闭“配置”边栏选项卡 。To return to the VM overview blade, close the Configuration blade by selecting the X in the upper right corner.
  4. 验证现在是否正确显示“DNS 名称”。Verify that the DNS name is now shown correctly.

后续步骤Next steps

VM 已经有公共 IP 和 DNS 名称,现在可以部署通用应用程序框架或服务,例如 nginx、MongoDB 和 Docker。Now that your VM has a public IP and DNS name, you can deploy common application frameworks or services such as nginx, MongoDB, and Docker.

也可以深入了解如何使用 Resource Manager,以获取生成 Azure 部署的相关提示。You can also read more about using Resource Manager for tips on building your Azure deployments.