我想在 shell Linux 程序中使用 Asterisk,大致如下:
asterisk -r && console dial 101
我该怎么做?谢谢。
答案1
您可以通过添加选项来运行星号命令-x
。
从手册页中:
-x command
Connect to a running Asterisk process and execute a command on a
command line, passing any output through to standard out and
then terminating when the command execution completes. Implies
-r when -R is not explicitly supplied.
因此你可以做类似的事情:
asterisk -rx "pjsip show endpoints"