drachtio / drachtio-dialogflow-phone-gateway

An open source telephony gateway for Dialogflow built using drachtio and freeswitch
MIT License
15 stars 6 forks source link

Call dropping after 30 seconds #4

Closed ruipfmendes closed 4 years ago

ruipfmendes commented 4 years ago

Hello!

So I'm trying to get this module to work but after I'm done configuring everything I make a call using zoiper and it is dropped at the 30-31-32 seconds mark. I believe the cause is something going wrong in the handshake which results in an "ACK Timeout". I went through all the steps included in the readme. I've also used drachtio-fsmrf a little in the past so I know a bit about how this works. It might be important to mention I'm installing everything in a AWS EC2 machine.

The only thing I added is the following code to make the app allow me to register any user using zoiper:

// Populate object req with the information about the authentic$
srf.use(regParser) ;
srf.register((req, res) => {
  res.send(200);
});

Logs below drachtio.log: https://gist.github.com/ruipfmendes/f42b02e23a38b3b3c98b28b5b2b20441 Freeswitch cli logs: https://gist.github.com/ruipfmendes/3859a26b8f14f7de0ef60eff355f8eeb

I changed the following IPs in the logs: machine public ip to MACHINE_PUBLIC_IP machine private ip to MACHINE_PRIVATE_IP my computer public IP to CLIENT_IP

Can someone give me some light on what I did wrong?

davehorton commented 4 years ago

ACK timeout means that the ip address in the Contact header of the 200 OK sent back to zoiper is unreachable. So my guess is that you have not configured the drachtio server properly with regard to its public address. Can you show your drachtio.conf.xml file?

davehorton commented 4 years ago

https://drachtio.org/docs/drachtio-server#contacts

pay attention to the part about the external-ip property

ruipfmendes commented 4 years ago

Ok, amazing thanks for the quick reply 🙇! it's fixed now! sorry I hadn't seen that documentation and this was the first time I tried installing outside my machine so I wasn't aware of what I had to do