【问题标题】:Access IIS 7.5 Express started by Visual Studio 2010 from VMWare Guest从 VMWare Guest 访问由 Visual Studio 2010 启动的 IIS 7.5 Express
【发布时间】:2012-01-21 11:17:11
【问题描述】:

我有 VS2010sp1 我用 C#、jQuery 等开发了一个 MVC 3 站点。当我开发时,我使用 IIS Express。客户现在希望我在 Windows XP 机器上通过 Internet Explorer 7 测试该站点。 我在 VMWare 上运行的虚拟机中有一台装有 IE7 的 XP 机器。 VMWare 机器网络适配器设置为桥接。 我在同一台机器上运行 VS2010、IIS Express 和 VMWare 工作站 8(A 64 位 Windows 7 Ultimate)。我似乎能够访问主机。我可以 ping 主机的名称,它以正确的 IP 地址回答,它还活着。 我应该如何配置 IIS Express 和虚拟机,以便我可以从虚拟机中运行的 IE7 访问我的网站?

谢谢

【问题讨论】:

    标签: visual-studio vmware iis-express


    【解决方案1】:

    我知道这个问题很老,但如果有人想要答案,仅供参考。

    http://www.hanselman.com/blog/WorkingWithSSLAtDevelopmentTimeIsEasierWithIISExpress.aspx

    我认为新的 IIS Express 8 可以以类似的方式进行配置。

    编辑:applicationHost.config 详细的配置步骤请参考网址^

    <site name="MvcApplication18" id="39">
      <application path="/" applicationPool="Clr4IntegratedAppPool">
         <virtualDirectory path="/" physicalPath="c:\users\scottha\documents\visual studio 2010\Projects\MvcApplication18\MvcApplication18" />
      </application>
      <bindings>
        <binding protocol="http"  bindingInformation="*:15408:localhost" />
        <binding protocol="https" bindingInformation="*:44302:localhost" />
        <binding protocol="http"  bindingInformation="*:80:hanselman-w500" />
        <binding protocol="https" bindingInformation="*:443:hanselman-w500" />
      </bindings>
    </site>
    

    【讨论】:

    • 虽然此链接可能会回答问题,但最好在此处包含答案的基本部分并提供链接以供参考。如果链接页面发生更改,仅链接的答案可能会失效。
    • 谢谢。我是新来的,没有想到这一点。我会记住的。
    【解决方案2】:

    您是否尝试过将 IIS 配置为使用本地 ip 托管您的网站,可能将端口号设置为 80,然后只需在 VM 上的浏览​​器中调用该页面。如果它在端口 80 上,我认为您在浏览器中键入地址时不需要添加端口号。

    请参阅here 了解如何配置 IIS express

    【讨论】:

      猜你喜欢
      • 2011-08-17
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-05
      • 2013-06-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多