简体   繁体   English

使用 vnet 集成的 azure 应用服务的静态 IP

[英]Static ip for azure app service using vnet integration

I trying to assign a static ip-address ,or at least control the out bound traffic, for an azure app service with out having to invest in app service environment (it's very expensive and not very flexible option).我尝试为 azure 应用程序服务分配一个静态 ip 地址,或至少控制出站流量,而不必投资应用程序服务环境(这是非常昂贵且不是很灵活的选项)。 Reading up on "vnet integration"( https://docs.microsoft.com/en-us/azure/app-service/web-sites-integrate-with-vnet )阅读“vnet 集成”( https://docs.microsoft.com/en-us/azure/app-service/web-sites-integrate-with-vnet

in the offical azure doc there exist options to force traffic to the vnet.在官方的 azure 文档中,存在强制流量到 vnet 的选项。 From there it should be possible to route the all traffic using UDRs through NAT-gateway.从那里应该可以通过 NAT 网关使用 UDR 路由所有流量。 Has any one here been able to make this work?这里有没有人能够完成这项工作? I have read conflicting reports.我读过相互矛盾的报告。

UPDATE Details of the scenario is as following.更新场景的详细信息如下。 I want to communicate with a system behind an internet facing firewall that have rules based on internet routable ips.我想与面向 Internet 的防火墙后面的系统进行通信,该防火墙具有基于 Internet 可路由 ip 的规则。 I want to leaverge app services and PaaS services in azure.我想在 azure 中离开应用程序服务和 PaaS 服务。

在此处输入图片说明

This it not possible with azure NAT Gateway or any other native PaaS servie in azure.这对于 azure NAT Gateway 或任何其他 azure 中的本机 PaaS 服务是不可能的。 There are several open feedback items related to this issue ( fixed outbound ip and Nat gateway with function app有几个与此问题相关的开放反馈项( 固定出站 ip带有功能应用程序的 Nat 网关

I have created a ticket ticket in the microsoft documention hoping that they will clarify this in their offical doc on vnet integration .我在微软文档中创建了一张票,希望他们能在他们关于vnet 集成的官方文档中澄清这一点。

One solution would be to leverage IaaS and install a custom reverse proxy on VM or container such as nginx.一种解决方案是利用 IaaS 并在 VM 或容器(如 nginx)上安装自定义反向代理。 This is not a option in my scenario due to the maintenance this wil requiere over time.由于随着时间的推移需要维护,这在我的场景中不是一个选项。

UPDATE更新

This is now supported https://azure.github.io/AppService/2020/11/15/web-app-nat-gateway.html .现在支持https://azure.github.io/AppService/2020/11/15/web-app-nat-gateway.html Microsoft announced support last week!微软上周宣布支持! I have tested the solution and it works great.我已经测试了该解决方案,并且效果很好。

It is possible, here is how to do it: https://sakaldeep.com.np/1159/azure-nat-gateway-and-web-app-vnet-integration-to-get-static-outbound-ip这是可能的,这里是如何做到这一点: https : //sakaldeep.com.np/1159/azure-nat-gateway-and-web-app-vnet-integration-to-get-static-outbound-ip

The route rule should have the vnet range in the address prefix and the outbound ip in the Next hop address.路由规则应该在地址前缀中包含 vnet 范围,在下一跳地址中包含出站 ip。

Also answered here: Web App outbound response not going through application gateway还在这里回答: Web App outbound response not going through application gateway

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

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