1、conf/vars.xml
<X-PRE-PROCESS cmd="set" data="default_password=11111111"/>
<X-PRE-PROCESS cmd="set" data="global_codec_prefs=OPUS,G722,PCMU,PCMA,VP8"/>
<X-PRE-PROCESS cmd="set" data="outbound_codec_prefs=OPUS,G722,PCMU,PCMA,VP8"/>
<X-PRE-PROCESS cmd="set" data="sound_prefix=$${sounds_dir}"/>
2、conf/internal.xml
<param name="accept-blind-reg" value="true"/>
<param name="ws-binding" value=":5066"/>
<param name="wss-binding" value=":7443"/>
<param name="apply-candidate-acl" value="ipv4"/>
3、autoload_configs/event_socket.conf.xml 设置主控
<configuration name="event_socket.conf" description="Socket Client">
<settings>
<param name="nat-map" value="false"/>
<param name="listen-ip" value="::"/>
<param name="listen-port" value="8021"/>
<param name="password" value="ClueCon"/>
<param name="apply-inbound-acl" value="lan"/>
<!--<param name="stop-on-bind-error" value="true"/>-->
</settings>
</configuration>
4、acl.conf.xml
<list name="ipv4" default="allow">
<node type="allow" cidr="0.0.0.0/0"/>
</list>
5、 话单处理(取消)
在C:\Program Files\FreeSWITCH\conf\autoload_configs\modules.conf.xml中释放<load module="mod_xml_cdr"/> 的注释。
C:\Program Files\FreeSWITCH\conf\autoload_configs\xml_cdr.conf.xml中修改注释,将
<param name="url" value="http://localhost:7786/huaDan/postHuaDan"/>中的value指向你的HTTP服务器地址。
6、 开启录音功能 conf/dialplan/default.xml、conf/dialplan/public/outbound_did.xml(取消)
conf/dialplan/outbound_did.xml
<include>
<extension name="Local_inbound_deal">
<condition field="destination_number" expression="^([0-9]\d+)$">
<action application="export" data="dialed_extension=$1"/>
<action application="set" data="call_timeout=30"/>
<action application="set" data="continue_on_fail=true"/>
<action application="export" data="record_sample_rate=8000"/>
<action application="export" data="RECORD_STEREO=true"/>
<action application="set" data="media_bug_answer_req=true"/>
<action application="set" data="RECORD_TITLE=Recording ${destination_number} ${caller_id_number} ${strftime(%Y-%m-%d %H:%M)}"/>
<action application="set" data="RECORD_COPYRIGHT=(c) 2011"/>
<action application="set" data="RECORD_SOFTWARE=FreeSWITCH"/>
<action application="set" data="RECORD_ARTIST=FreeSWITCH"/>
<action application="set" data="RECORD_COMMENT=FreeSWITCH"/>
<action application="set" data="RECORD_DATE=${strftime(%Y-%m-%d %H:%M)}"/>
<!-- <action application="set" data="RECORD_STEREO=true"/> -->
<action application="record_session" data="$${base_dir}/recordings/${strftime(%Y)}/${strftime(%m%d)}/${caller_id_number}/${strftime(%Y-%m-%d-%H-%M-%S)}_${destination_number}_${caller_id_number}.mp3"/>
<action application="export" data="hangup_after_bridge=false"/>
<action application="socket" data="192.168.33.109:8084 async full"/>
</condition>
</extension>
</include>
conf/dialplan/public/default.xml
<extension name="Local_ExtensionEsl">
<condition field="destination_number" expression="^([0-9]\d+)$">
<action application="info"/>
<!-- <action application="answer"/> -->
<action application="export" data="dialed_extension=$1"/>
<action application="set" data="call_timeout=30"/>
<action application="set" data="continue_on_fail=true"/>
<action application="export" data="record_sample_rate=8000"/>
<action application="export" data="RECORD_STEREO=true"/>
<action application="set" data="media_bug_answer_req=true"/>
<action application="set" data="RECORD_TITLE=Recording ${destination_number} ${caller_id_number} ${strftime(%Y-%m-%d %H:%M)}"/>
<action application="set" data="RECORD_COPYRIGHT=(c) 2011"/>
<action application="set" data="RECORD_SOFTWARE=FreeSWITCH"/>
<action application="set" data="RECORD_ARTIST=FreeSWITCH"/>
<action application="set" data="RECORD_COMMENT=FreeSWITCH"/>
<action application="set" data="RECORD_DATE=${strftime(%Y-%m-%d %H:%M)}"/>
<!-- <action application="set" data="RECORD_STEREO=true"/> -->
<action application="record_session" data="$${base_dir}/recordings/${strftime(%Y)}/${strftime(%m%d)}/${caller_id_number}/${strftime(%Y-%m-%d-%H-%M-%S)}_${destination_number}_${caller_id_number}.mp3"/>
<action application="export" data="park_after_bridge=true"/>
<action application="export" data="hangup_after_bridge=false"/>
<action application="socket" data="192.168.33.109:8084 async full"/>
</condition>
</extension>
7.conf/autoload_configs/modules.conf.xml 动态配置注册
//打开注释
<load module="mod_xml_curl"/>
8.conf/autoload_configs/xml_curl.conf.xml
<binding name="directory">
<param name="gateway-url" value="http://192.168.33.109/api/fs_curl"/>
</binding>
9.编译地址:https://blog.csdn.net/u012121105/article/details/74238595
问题解决:https://blog.csdn.net/singleroot/article/details/52298620