Giter VIP home page Giter VIP logo

amiws's People

Contributors

dependabot[bot] avatar kohanis avatar kvishnivetsky avatar shkiperon avatar staskobzar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

amiws's Issues

Sending multiple Variable in Originate and other supported AMI actions

Is it possible to send multiple 'Variable' key in 'Originate' and other AMI actions that supports this functionality?
I've tried three ways:

  1. Make long string for 'Variable' key
"var1=some1\r\nVariable: var2=some2\r\nVariable: var3=some3"
  1. Make included JSON-object for 'Variable' key
{
  "var1": "some1",
  "var2": "some2",
  "var3": "some3"
}
  1. Make included list of vars for 'Variable' key
[
  "var1=some1",
  "var2=some2",
  "var3=some3"
]

In first case on Asterisk side I see only first variable with "modified tail" - "some1rnVariable: var2=some2rnVariable: var3=some3".
In second and third cases I see empty variables.

I want to send multiple variables to Asterisk without extra manipulations on Asterisk side.

Problems compiling Centos 8

Hi, I'm having trouble compiling on Centos 8:
CentOS Linux release 8.3.2011

[root@150620211711 amiws-master]# ./configure --with-ssl
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for ranlib... ranlib
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking whether make supports the include directive... yes (GNU style)
checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for gcc option to accept ISO Standard C... (cached) none needed
checking for yaml_parser_initialize in -lyaml... yes
checking for library containing CRYPTO_new_ex_data... -lcrypto
checking for library containing SSL_library_init... no
configure: error: openssl library not found

The OpenSSL libraries are already installed:

[root@150620211711 amiws-master]# rpm -qa |grep openssl
compat-openssl10-1.0.2o-3.el8.x86_64
openssl-1.1.1g-15.el8_3.x86_64
openssl-perl-1.1.1g-15.el8_3.x86_64
apr-util-openssl-1.6.1-6.el8.x86_64
openssl-pkcs11-0.4.10-2.el8.x86_64
openssl-devel-1.1.1g-15.el8_3.x86_64
openssl-ibmpkcs11-1.0.2-1.el8.x86_64
openssl-libs-1.1.1g-15.el8_3.x86_64
anope-openssl-2.0.9-3.el8.x86_64

I thank you in advance for your help.

Constant disconnecting?

A couple questions

Trying to isolate an issue, I am having. I am using amiws with about 80 high traffic asterisk servers. It seems be constantly reconnecting to some of them. Its likely something on my end, but I am trying to narrow it down. Do you know if this program does fine on that kind of load?

Is there some way to set an ID for each server instead of using the provided one? or maybe the hostname/ip instead?
No worries if not.

Also thank you so much for this! Saved me so much time and effort. Wonderful program.

Multi-tenant Configuration

Is is possible to specify somewhere a global filter so that customer specific information is all that is returned? For example every queue, sip peer, etc begins with customer-XXXX. So customername-sales queue, or customername-100 for extensions.

Send event command line

Hello, one question ...
Is it possible to send a message using the command line so that only browsers receive the event without asterisk being involved?
The event could only reach the haulers with a different identification code.
Nothing would change, it would be just another feature.

project still working or not ?

hello dear and thanks for nice project,

I try to run, everything is ok after build and install,
tcp 0 0 0.0.0.0:8000 0.0.0.0:* LISTEN 9535/amiws

and in asterisk consol AMI login, but when try to open in web, nothing to show ...

amiws

**Cards**

Cards can be added to your board to track the progress of issues and pull requests. You can also add note cards, like this one!

Only "Not Found" appears on the screen

Hello

I am trying to use this service because in my current structure many sessions are opened and closed constantly and with a time the manager happens to refuse connections.
The installation and startup of amiws is done without any problems.
I chose not to use ssl.

Linux CentOS 6.0
Asterisk: 1.6.2.24
Asterisk server: 192.168.100.254
Amiws server: 192.168.100.251

The configuration file looks like this:

log_facility : 40
log_level : 6
ws_port : 8000
web_root : /var/www/amiws/web_root
auth_domain : example.com
auth_file : /var/www/.htaccess

amihosts:

  • name: ast01.example.com
    port: 5038
    host: 192.168.100.254
    username: teste
    secret: 123456

The connection is established with asterisk without problems.

amiws[6775]: AMI hosts connecting.
amiws[6775]: Listening Web Socket port 8000
amiws[6775]: Enabling HTTP Basic authentication.
amiws[6775]: AMI version: 1.1.0
amiws[6775]: AMI login with user: teste to server: ast01.example.com

The problem is that I can not access through port 8000.
In the first attempt to access the login screen appears, I enter the credentials, but only "Not Found" appears on the screen.

http://192.168.100.251:8000/

This appears when I try to access the browser:

amiws[6775]: New HTTP connection from 192.168.100.98:50833
amiws[6775]: Closed New Web Socket connection from 192.168.100.98:50833

Can anyone guide me?
Thank you very much in advance.

config error when put ./configure --with-ssl on debian 11 (bulllseye)

Hi,

thank you for your greatjob!
here is log

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for ranlib... ranlib
checking for gcc... gcc

checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for gcc option to accept ISO Standard C... (cached) none needed
checking for yaml_parser_initialize in -lyaml... yes
checking for library containing CRYPTO_new_ex_data... -lcrypto
checking for library containing SSL_library_init... no

configure: error: openssl library not found  <--- how could i find ?

Problem Install

i have a problem with instalation:

root@teste-painel-1:~/amiws# ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for ranlib... ranlib
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for gcc option to accept ISO C99... none needed
checking for gcc option to accept ISO Standard C... (cached) none needed
checking for yaml_parser_initialize in -lyaml... yes
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking syslog.h usability... yes
checking syslog.h presence... yes
checking for syslog.h... yes
checking for ar... ar
checking the archiver (ar) interface... ar
checking for gawk... (cached) mawk
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating doc/Doxyfile
config.status: creating doc/Makefile
config.status: creating src/Makefile
config.status: creating src/lib/Makefile
config.status: creating test/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands

root@teste-painel-1:~/amiws# make
make all-recursive
make[1]: Entering directory '/root/amiws'
Making all in src
make[2]: Entering directory '/root/amiws/src'
Making all in lib
make[3]: Entering directory '/root/amiws/src/lib'
make[3]: Nothing to be done for 'all'.
make[3]: Leaving directory '/root/amiws/src/lib'
make[3]: Entering directory '/root/amiws/src'
make[3]: Nothing to be done for 'all-am'.
make[3]: Leaving directory '/root/amiws/src'
make[2]: Leaving directory '/root/amiws/src'
Making all in test
make[2]: Entering directory '/root/amiws/test'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/root/amiws/test'
make[2]: Entering directory '/root/amiws'
make[2]: Leaving directory '/root/amiws'
make[1]: Leaving directory '/root/amiws'

Specific Command

Hello

I noticed that the 'core show hints' command does not work.
All other commands work perfectly, only this one does not work.
I really need this command, is there anything I can do?

start command to send data

Hi, you can have the websocket server (amiws) send data to the client only after receiving a command from the Javascript script.
For example "ws.send ('start')"?
if yes, how can i do?

Help with asterisk 15.4.1

Hello, I need your help again.
I upgraded my asterisk version to 15.4.1, and some commands are not responding correctly.

screenshot_1

On the first request I sent 'core show uptime' and got the answer in the 'Output' object correctly.
On the second request I sent 'queue show' in this case the 'Output' object returned empty.
In the third request I sent 'pjsip list endpoints' in this case the 'Output' object returned empty.

Notice that the response appears in the event but not in the 'Output' object, it is as if the json was not formatted correctly and because this notation can not be decoded.
I am using the latest version of 'amiws-master' and my linux is Centos 7.

Please, I need your help.

Filter received events based on AMIServerID

Hi,

Would it be possible to filter events based on the AMIServerID when opening a WebSocket? I want to use this as a proxy for multiple systems and I don't want every connected system to receive events from all connected PBX's / AMI Hosts.

Maybe by providing a header with the AMIServerID when opening the WebSocket or sending an action after the connection has been opened?

For example in Python:
ws.connect(ws_end_point, header={'AMIServerID': 1}

Token authentication in websocket

Congratulations on the excellent work.

I did all the tests and it works as indicated, I just have a question, is it possible to add token authentication to the websocket?

If this is how I could do it, if not, where could I start?

I am attentive, thank you. (Excuse my English, it is not my native language.)

enhancement

my friend if you check duration from active channels after refresh well be enhancement because duration run on the front end and it reset in refresh page

Connection to server has been lost. Trying to reconnect...

Hi!

I installed amiws onto FreePBX server and made all settings in conf files
The "manager show connected" command shows that ami user connected as well, but in web interface I see message "Connection to server has been lost. Trying to reconnect..."
Where I can find logs that can show me what the cause of this message?

Thanks in advance!

getting error: YAML library not found in CentOS 7

Hello,

We are trying to install amiws in CentOS 7. We getting below error during ./configure even though we have installed latest libyaml
configure: error: YAML library not found.
>> Install libyaml and retry.

[root@Centos7 amiws-master]# yum install libyaml
Loaded plugins: langpacks
Package libyaml-0.1.4-11.el7_0.x86_64 already installed and latest version
Nothing to do

Send AMI Actions to one of the amihosts

Hello,

I like the project, very good implementation very much, thanks for that.

I want to ask a question, as I'm having multiple servers connected to the AMIws instance, and I want to send an AMI command to one of them.

When I send the request, I get a reply from all the servers connected that the action has been executed on all servers.

I send the request through web-socket as follows:

{
"type":2,
"server_id":1,
"server_name":"server",
"ssl":false,
"data":{
"Action":"QueueAdd",
"ActionID":"actid",
"Queue":"queue",
"Interface":"SIP/ext",
"Penalty":"0",
"Paused":"true",
"MemberName":"name"
}
}

Thanks in advance.

Response too slow

Hey

This is my log when I send a command to server

Response Connected Time 3649 ms
Send cmd {"Action":"CoreStatus","ActionID":"getConnectedServers"}
Response Time 3987 ms
Received message: { "type": 4, "server_id": 1, "server_name": "callevo11", "ssl": false, "data": {"Response": "Error","Message": "Too many lines in message or allocation failure"}}

Why too slow and why this error message ?

Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.