无法将 Azure Web App 集成到 Vnet

Cannot integrate Azure Web App to Vnet

我在 Azure 上的 Vnet 运行 上有 Web 应用程序和 SQL 服务器虚拟机。我想将 Web App 集成到虚拟网络中。

我关注了 https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-integrate-with-vnet#managing-the-vnet-integrations

1) 我创建了网关子网和网关。

2)我打开了“应用服务->网络->VNet集成->设置->虚拟网络可见但是是灰色的!

我需要做什么才能将 Web App 连接到 Vnet?

VNet 变灰的原因有多种,包括:

• VNet 位于您的帐户有权访问的另一个订阅中

VNet 未启用指向站点

• VNet 没有动态路由网关

按照你的步骤,这个问题可能是你的VPN网关没有配置P2S地址池导致的。

我在实验室做了测试,终于可以把我的Web App集成到Vnet上了。 您应该如下图检查这两点:

您的 VPN ponit-to-site 配置:

您的 VNet 连接设备:

如何在资源管理器 VNet 中启用点到站点:

要使用网关和点到站点配置资源管理器 VNet,您可以使用此处记录的任一 PowerShell,Configure a Point-to-Site connection to a virtual network using PowerShell or use the Azure portal as documented here, Configure a Point-to-Site connection to a VNet using the Azure portal。执行此功能的 UI 尚不可用。请注意,您需要为点到站点配置创建证书。这是在您将 WebApp 连接到 VNet 时自动配置的。