【问题标题】:Reach Owin Self Hosted app in Azure from outside Azure从 Azure 外部访问 Azure 中的 Owin 自托管应用程序
【发布时间】:2016-07-23 03:56:21
【问题描述】:

我有 .NET 中的标准 OWIN 示例控制台应用程序 一个启动类,监听 80 端口。

在标准 Windows Azure v2 VM 上运行此应用 (资源经理)

我为端口 80 添加了一个端点并打开了防火墙 端口 80。

我可以使用本地 ip 或 localhost:80 在 VM 上运行此示例。

我无法从虚拟机外部调用地址

我可以从 Azure 外部 ping VM 上的端口 80。

问题:我无法调用地址(公共 ip / 或分配的 cloudapp 地址) 在 Azure 之外。我错过了什么?

谢谢

var url = "http://+:80";

    using (WebApp.Start<Startup>(url))
    {
        Console.WriteLine("Running on {0}", url);
        Console.WriteLine("Press enter to exit");
        Console.ReadLine();
    }

【问题讨论】:

  • "我可以从 Azure 外部 ping VM 上的端口 80" - 不,你不能。 Azure 不支持来自外部流量的 ICMP。

标签: .net azure owin


【解决方案1】:

据我所知,我们无法从外部 Azure 目录访问自托管应用程序。我搜索了以下解决方法来实现此目的:

1) Service Fabric Web API services with OWIN self-hosting

2) self-host an OWIN applications inside a Microsoft Azure worker role

3)Running an OWIN Self-Hosted Web API in a Windows Docker Container

4) 安装 IIS,将 Web API 应用程序部署到 Azure VM。

【讨论】:

    猜你喜欢
    • 2016-03-02
    • 2020-06-03
    • 2017-09-24
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-09-28
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多