CyCoreSystems / asterisk-k8s-demo

Demo of scalable Asterisk on Kubernetes
Apache License 2.0
158 stars 72 forks source link

Can't expose UDP on AWS EKS #17

Open eberladin opened 3 years ago

eberladin commented 3 years ago

Is any way to make SIP in Kubernetes work on AWS ? When i do expose my Kamailio outside: k expose deployment kamailio-sip --name kamailio-sip-udp --type LoadBalancer --port 5060 --target-port 5060 --protocol UDP

It doesn't work on AWS EKS, i got ERROR: Warning SyncLoadBalancerFailed 4m57s (x16 over 55m) service-controller Error syncing load balancer: failed to ensure load balancer: Protocol UDP not supported by LoadBalancer

And if even i make it work with manually configured AWS NLB, the SIP routing is broken:

reqest: SIP UAC --> sip --> AWS LB -> sip --> pod reply: pod --> sip --> default route --> SIP UAC

Bob--------------------------AWS LB----------------------SIP Pod-----------EKS node external ip |-----------REGISTER------- >| -------REGISTER---------- >|
|<----------------------------------200 OK-------------------------------------------|

The SIP reply messages going directly via k8s node external IP. Thanks for any recomendations.