基于Centos7 安装
docker run --hostname=freeswitch18 --name=freeswitch18 --net=host --privileged -it -d centos:7.6.1810 /usr/sbin/init
[root@demo1 ~]# docker exec -it freeswitch18 bash
安装必要的包
yum -y install yum-utils autoconf automake libtool unixODBC-devel zlib-devel libjpeg-devel sqlite-devel.x86_64 pcre* speex* ldns-devel libidn-devel unbound-devel libsndfile-devel libedit-devel libtiff-devel lua lua-devel yasm curl-devel erlang opus-devel yum-plugin-ovl centos-release-scl rpmdevtools yum-utils git vim wget erlang -y
yum install gcc-c++ libstdc++-devel -y
yum install -y https://files.freeswitch.org/repo/yum/centos-release/freeswitch-release-repo-0-1.noarch.rpm epel-release
yum-builddep -y freeswitch --skip-broken
cd /usr/local/src
wget https://cmake.org/files/v3.7/cmake-3.7.2.tar.gz
tar -zxvf cmake-3.7.2.tar.gz
cd cmake-3.7.2/
./bootstrap
gmake
gmake install
/usr/local/bin/cmake --version
ln -s /usr/local/bin/cmake /usr/bin/
cd ..
git clone -b v1.8 https://git.oschina.net/nwaycn/freeswitch.git
cd /usr/local/src/freeswitch
./bootstrap.sh -j
./configure --enable-portable-binary \
--prefix=/usr --localstatedir=/var --sysconfdir=/etc \
--with-gnu-ld --with-python --with-erlang --with-openssl \
--enable-core-odbc-support --enable-zrtp
make
make -j install
make -j cd-sounds-install
make -j cd-moh-install
验证:
[root@freeswitch18 /]# freeswitch -nc
158 Backgrounding.
+OK log level [7]
freeswitch@freeswitch18> version
FreeSWITCH Version 1.8.7+git~20190702T200609Z~6047ebddfc~64bit (git 6047ebd 2019-07-02 20:06:09Z 64bit)
freeswitch@freeswitch18> /exit
[root@freeswitch18 freeswitch]#