简体   繁体   English

如何在 Azure 中使用虚拟机托管网站?

[英]How to host Website using Virtual Machine in Azure?

I have created a virtual machine windows server 2012 on azure and I have bought a domain name from godaddy.com .My website folder is in htdocs folder of xampp.我在 azure 上创建了一个虚拟机 windows server 2012,并且我从 godaddy.com 购买了一个域名。我的网站文件夹在 xampp 的 htdocs 文件夹中。 I have also created the virtual host in Virtual machine and I have given the IP address of it to the domain name.我还在虚拟机中创建了虚拟主机,并将其IP地址赋予了域名。 I am unable to figure out what to do next .我不知道下一步该做什么。 Please help me out !请帮帮我!

If you web server is up and running in your VM you just need to open the external endpoints now.如果您的 Web 服务器已启动并在您的 VM 中运行,您现在只需要打开外部端点。

From Azure portal >> Navigate to your VM >> Endpoints >> Add >> Type name, port and select protocol从 Azure 门户 >> 导航到您的 VM >> 端点 >> 添加 >> 键入名称、端口并选择协议

For you custom domain, you have to go to godaddy dns manager and add a new host (A) entry pointing to your VM public ip.对于您的自定义域,您必须转到godaddy dns 管理器并添加一个指向您的VM 公共IP 的新主机(A) 条目。

Also make sure windows firewall is not blocking connections.还要确保 Windows 防火墙没有阻止连接。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM