Opensips - housekeeper-software/tech GitHub Wiki
查看opensips版本
https://www.cnblogs.com/initialjiang/p/13492981.html
https://blog.csdn.net/sinat_20184565/article/details/85255213
删除悬空镜像
docker rmi $(docker images -f "dangling=true" -q)
install mysql-client
wget https://repo.mysql.com//mysql-apt-config_0.8.22-1_all.deb https://www.claudiokuenzler.com/blog/1197/mysql-apt-repository-error-signature-verification-public-key
https://www.nb6.top/2021/03/debian-10-mysql-5.7/
RUN mkdir /home/opensips RUN cd /home/opensips && wget https://opensips.org/pub/opensips/2.4.11/opensips-2.4.11.tar.gz
mysql-community-client mysql-community-server
opensips 一个配置
https://www.cnblogs.com/initialjiang/p/13449745.html
docker build --network=host -t sip:2.4 .
docker run -dit --name=sip --network=mynet --ip 172.18.12.1 -p 25060:25060 -p 18888:18888 -p 18889:18889 -p 18888:18888/udp sip:2.4 /bin/bash
#python3, python3-distutils python3.7-dev
libnetfilter-conntrack-dev
https://blog.csdn.net/lvwx369/article/details/120748676
FROM debian:10 as builder USER root
ENV DEBIAN_FRONTEND noninteractive
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1
COPY sources.list /etc/apt/sources.list
RUN apt-get update &&
apt-get -y install apt-utils gnupg ca-certificates wget curl
for install mediaproxy
RUN wget -O /etc/apt/trusted.gpg.d/agp-debian-key.gpg http://download.ag-projects.com/agp-debian-key.gpg RUN echo "\ndeb http://ag-projects.com/debian unstable main" >> /etc/apt/sources.list RUN echo "deb-src http://ag-projects.com/debian unstable main\n" >> /etc/apt/sources.list
for install mysql client
COPY mysql.list /etc/apt/sources.list.d COPY RPM-GPG-KEY-mysql-2022 /home RUN apt-key add /home/RPM-GPG-KEY-mysql-2022
RUN apt-get update &&
apt-get -y install procps net-tools build-essential autoconf automake libtool bzip2 unzip pkg-config bison flex libncurses5 libncurses5-dev vim libssl-dev mysql-client libmysqlclient-dev python3 python3-dev libnfnetlink-dev libmnl-dev libip4tc-dev iptables-dev libnetfilter-conntrack-dev python3-application python3-gnutls
python3-application http://download.ag-projects.com/others/
python3-gnutls http://download.ag-projects.com/others/
python3-twisted
python3-zope.interface
fat install
FROM debian:10 as builder
USER root
ENV DEBIAN_FRONTEND noninteractive
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1
COPY sources.list /etc/apt/sources.list
RUN apt-get update && \
apt-get -y install apt-utils gnupg ca-certificates wget curl
# for install mediaproxy
RUN curl -o /etc/apt/trusted.gpg.d/agp-debian-key.gpg http://download.ag-projects.com/agp-debian-key.gpg
RUN echo "deb http://ag-projects.com/debian buster main" >> /etc/apt/sources.list
RUN echo "deb-src http://ag-projects.com/debian buster main\n" >> /etc/apt/sources.list
# for install mysql client
RUN curl -s http://repo.mysql.com/RPM-GPG-KEY-mysql-2022 | apt-key add -
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-apt-config\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-5.7\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-tools\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb-src http://repo.mysql.com/apt/debian/ buster mysql-5.7\n" >> /etc/apt/sources.list.d/mysql.list
# for opensips
RUN curl https://apt.opensips.org/opensips-org.gpg -o /usr/share/keyrings/opensips-org.gpg
RUN echo "deb [signed-by=/usr/share/keyrings/opensips-org.gpg] https://apt.opensips.org buster 2.4-releases\n" >> /etc/apt/sources.list.d/opensips.list
RUN echo "deb [signed-by=/usr/share/keyrings/opensips-org.gpg] https://apt.opensips.org buster cli-nightly\n" >> /etc/apt/sources.list.d/opensips.list
RUN apt-get update && \
apt-get -y install procps net-tools build-essential autoconf automake libtool bzip2 unzip pkg-config bison flex libncurses5 libncurses5-dev vim libssl-dev mysql-client libmysqlclient-dev python3 python3-dev libnfnetlink-dev libmnl-dev libip4tc-dev iptables-dev libnetfilter-conntrack-dev python3-application python3-gnutls opensips \
opensips-b2bua-module opensips-berkeley-module opensips-carrierroute-module opensips-cgrates-module \
opensips-compression-module opensips-console opensips-cpl-module \
opensips-dbhttp-module opensips-dialplan-module opensips-emergency-module opensips-geoip-module opensips-http-modules opensips-identity-module \
opensips-jabber-module opensips-json-module opensips-ldap-modules opensips-lua-module opensips-memcached-module opensips-mysql-module opensips-mongodb-module \
opensips-perl-modules opensips-postgres-module opensips-presence-modules opensips-rabbitmq-modules opensips-radius-modules opensips-redis-module \
opensips-regex-module opensips-restclient-module opensips-sctp-module opensips-siprec-module opensips-snmpstats-module opensips-sqlite-module opensips-tls-module \
opensips-wss-module opensips-tlsmgm-module opensips-unixodbc-module opensips-xmlrpc-module opensips-xmpp-module \
mediaproxy-relay
RUN cd /tmp && wget http://download.ag-projects.com/MediaProxy/mediaproxy-4.0.4.tar.gz && tar zxvf mediaproxy-4.0.4.tar.gz \
&& cd mediaproxy-4.0.4 && python3 setup.py install
COPY opensips.cfg /etc/opensips/opensips.cfg
COPY opensipsctlrc /etc/opensips/opensipsctlrc
COPY config.ini /etc/mediaproxy/config.ini
COPY tls /etc/mediaproxy/tls
good
FROM debian:10 as builder
USER root
ENV DEBIAN_FRONTEND noninteractive
ENV APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1
COPY sources.list /etc/apt/sources.list
RUN apt-get update && \
apt-get -y install apt-utils gnupg ca-certificates wget curl
# for install mediaproxy
RUN curl -o /etc/apt/trusted.gpg.d/agp-debian-key.gpg http://download.ag-projects.com/agp-debian-key.gpg
RUN echo >> /etc/apt/sources.list
RUN echo "deb http://ag-projects.com/debian buster main" >> /etc/apt/sources.list
RUN echo "deb-src http://ag-projects.com/debian buster main\n" >> /etc/apt/sources.list
# for install mysql client
RUN curl -s http://repo.mysql.com/RPM-GPG-KEY-mysql-2022 | apt-key add -
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-apt-config\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-5.7\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb http://repo.mysql.com/apt/debian/ buster mysql-tools\n" >> /etc/apt/sources.list.d/mysql.list
RUN echo "deb-src http://repo.mysql.com/apt/debian/ buster mysql-5.7\n" >> /etc/apt/sources.list.d/mysql.list
# for opensips
RUN curl https://apt.opensips.org/opensips-org.gpg -o /usr/share/keyrings/opensips-org.gpg
RUN echo "deb [signed-by=/usr/share/keyrings/opensips-org.gpg] https://apt.opensips.org buster 2.4-releases\n" >> /etc/apt/sources.list.d/opensips.list
RUN echo "deb [signed-by=/usr/share/keyrings/opensips-org.gpg] https://apt.opensips.org buster cli-nightly\n" >> /etc/apt/sources.list.d/opensips.list
RUN apt-get update && \
apt-get -y install procps net-tools build-essential autoconf automake libtool bzip2 unzip pkg-config bison flex libncurses5 libncurses5-dev vim libssl-dev mysql-client libmysqlclient-dev python3 python3-dev libnfnetlink-dev libmnl-dev libip4tc-dev iptables-dev libnetfilter-conntrack-dev python3-application python3-gnutls opensips \
opensips-b2bua-module opensips-berkeley-module opensips-carrierroute-module opensips-cgrates-module \
opensips-compression-module opensips-console opensips-cpl-module \
opensips-dbhttp-module opensips-dialplan-module opensips-emergency-module opensips-geoip-module opensips-http-modules opensips-identity-module \
opensips-jabber-module opensips-json-module opensips-ldap-modules opensips-lua-module opensips-memcached-module opensips-mysql-module opensips-mongodb-module \
opensips-perl-modules opensips-postgres-module opensips-presence-modules opensips-rabbitmq-modules opensips-radius-modules opensips-redis-module \
opensips-regex-module opensips-restclient-module opensips-sctp-module opensips-siprec-module opensips-snmpstats-module opensips-sqlite-module opensips-tls-module \
opensips-wss-module opensips-tlsmgm-module opensips-unixodbc-module opensips-xmlrpc-module opensips-xmpp-module \
mediaproxy-dispatcher
COPY opensips.cfg /etc/opensips/opensips.cfg
COPY opensipsctlrc /etc/opensips/opensipsctlrc
COPY config.ini /etc/mediaproxy/config.ini
COPY media-disp-tls/tls /etc/mediaproxy/tls