question

JamieNeubert-8006 avatar image
0 Votes"
JamieNeubert-8006 asked SaiKishor-MSFT edited

Use public IP of other virtual network

Hi.

I am using AKS and want to use a predefined virtual network in Azure. Is that possible?
The reason that I want to do it is I'm connecting to a host from one of the servers which only allows connections from a specific IP (allow-list).
Or is it possible to later use the predefined virtual network as the "master" of the other virtual network created dynamically by the cluster creation?

Another solution I've thought of is using a VPN client in AKS. Is that possible to do with Azure CNI and how would one do it?
I already have an OpenVPN server running on a different server, so if it was possible to connect to that for a specific request to a IP that would also be awesome.

azure-virtual-networkazure-kubernetes-service
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

I found out how to use another virtual network during the cluster creation wit the flag --vnet-subnet-id.

That is not enough though since it still schedules a new public IP address, which makes sense since there was only one public IP attached to the vnet before.

Is it possible to attach it to a load balancer and configure a path on the load balancer to point to the AKS cluster and other traffic to go to the old internal IP?

0 Votes 0 ·

1 Answer

SaiKishor-MSFT avatar image
0 Votes"
SaiKishor-MSFT answered SaiKishor-MSFT edited

@JamieNeubert-8006 Thank you for reaching out to Microsoft Q&A. We apologize for the delay in response.

I understand that you want to attach your AKS to a Load Balancer and point traffic to the AKS Cluster and remaining traffic to the old internal IP.

Here is some documentation to setup AKS with Load Balancer-

Public Load Balancer: https://docs.microsoft.com/en-us/azure/aks/load-balancer-standard
Internal Load Balancer: https://docs.microsoft.com/en-us/azure/aks/internal-lb

However, you cannot route traffic based on paths using a Load Balancer and may need an Application Gateway to that. Here is a document that explains how to integrate an application gateway with AKS- https://azure.microsoft.com/en-us/blog/application-gateway-ingress-controller-for-azure-kubernetes-service/

Here is an similar setup i.e., Multiple Site Hosting on Azure Application Gateway integrated with Azure AKS that may help you.

Hope this helps. Please let usknow if you require any further assistance regarding this and we will be happy to help. Thank you!

Remember:

Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.

Want a reminder to come back and check responses? Here is how to subscribe to a notification.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.