nvisibleinc / go-ari-proxy Goto Github PK
View Code? Open in Web Editor NEWAsterisk REST Interface proxy system written in Go
License: Apache License 2.0
Asterisk REST Interface proxy system written in Go
License: Apache License 2.0
Would be handy to have the proxy reconnect?
This means as soon as I get a dialog, I can't just start consuming the queues etc - I have to wait a small period of time - it would be easier if the queues were definitely made before sending the initial dialog to say, YES theres a session
Is this proxy capable of handling multiple Asterisk instances at the same time ?
Implement some of the extra code checks on Travis CI from this article: https://serifandsemaphore.io/tools-to-help-you-go-d6f782055ce7#.9e4xug2l0
To keep the container really small, update the Dockerfile we have now to use a scratch build rather than a FROM:golang so that we can flatten things down to just a few megs rather than 200MB+
Update Docker section in documentation (Relates to #23 )
I think it needs changing to golang.org/x/net/websocket
and the compile succeeded with that but I'm not 100%
Will issue a PR in a moment
I'd like to be able to pass into the go-ari-proxy command the location of the config instead of relying on it being in the same directory as where you initialise the command from
Why do not the associated channels close when the call ends, do not delete the associated queues?
Much appreciate this application.
Should config.json read
"websocket_url": "http://localhost:8080"
OR
"websocket_url": "ws://localhost:8080"
Do you have a more concrete example on how to implement the config file. The example given is not very easy to follow.
Thanks
When comparing events from asterisk and go-ari-proxy, one can see that the proxy formats the asterisk event as a string, which makes deserializing pretty hard:
asterisk event:
{"type":"StasisStart","timestamp":"2017-11-30T14:37:15.796+0100","application":"foo","asterisk_id":"aa:00:00:36:fa:ca","channel":{"id":"1512049035.123","dialplan":{"context":"default","exten":"1000","priority":2},"name":"PJSIP/1001-00000061","connected":{"name":"","number":""},"state":"Ring","creationtime":"2017-11-30T14:37:15.794+0100","caller":{"name":"","number":"1001"},"accountcode":"","language":"en"},"args":[]}
go-ari-proxy:
{"server_id":"good_server","timestamp":"2017-11-30T14:37:15.796635341+01:00","type":"StasisStart","ari_body":"{\"type\":\"StasisStart\",\"timestamp\":\"2017-11-30T14:37:15.796+0100\",\"application\":\"foo\",\"asterisk_id\":\"aa:00:00:36:fa:ca\",\"channel\":{\"id\":\"1512049035.123\",\"dialplan\":{\"context\":\"default\",\"exten\":\"1000\",\"priority\":2},\"name\":\"PJSIP/1001-00000061\",\"connected\":{\"name\":\"\",\"number\":\"\"},\"state\":\"Ring\",\"creationtime\":\"2017-11-30T14:37:15.794+0100\",\"caller\":{\"name\":\"\",\"number\":\"1001\"},\"accountcode\":\"\",\"language\":\"en\"},\"args\":[]}"}
Is there a reason why this is so or is this merely a bug?
We have a use case that works with direct http-ari: creating a channel with ari.channels.create(). StasisStart would not have been sent at the time of this create, so no channel is available to talk on. Need to be able to initiate setup from the proxy side.
I'm looking for a way to setup WebRTC in a cloud box (16.1.1) already running go-ari-proxy.
TLS is strongly recommended -> https://wiki.asterisk.org/wiki/display/AST/WebRTC.
So I guess I will need TLS inside go-ari-library.
In your opinion adding TLS to the library how should impact on go-ari-proxy?
I have setup a sort of ARI Bridges Engine thanks to go-ari-library/-proxy.
It's a quite dumb conference application, driven by one external client application: my early stage ARI application works well while operating some business logics around with very little load.
Thx.
ciao
Add information now that we have a Dockerfile added to the repository. Update placeholder for Docker, and reference the automated builds that we have on Docker hub.
I am trying to use a simple rabbitMQ consumer and producer for interacting with the ARI proxy and cannot seem to get the syntax correct for sending commands. Can you please update the readme to include an example of how the json should be formatted for the message to be processed. Right now I
I am only having this experience regardless of what I send in.
DEBUG: 2017/12/13 23:40:22 go-ari-proxy.go:332: jsonCommand is {"url":"/bridges/EPLX6NMHBBRFI6BARID6KOOAG4XSLKG/record", "body": {"name":"EPLX6NMHBBRFI6BARID6KOOAG4XSLKG", "format":""}}
DEBUG: 2017/12/13 23:40:22 go-ari-proxy.go:346: fullURL is http://<hidden>:8088/ari/bridges/EPLX6NMHBBRFI6BARID6KOOAG4XSLKG/record?api_key=<hidden>:<hidden>
DEBUG: 2017/12/13 23:40:22 go-ari-proxy.go:352: Response body is {"message":"Invalid method"}
DEBUG: 2017/12/13 23:40:22 go-ari-proxy.go:366: sendJSON is {"unique_id":"","status_code":405,"response_body":"{\"message\":\"Invalid method\"}"}
Just getting up to speed and noticed theres no information on the config file needed to make the proxy work
Looking to fix this myself once I've looked at the source code
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.