Hi Davide may be it can help here is docker file for compiling and running rtp engine
FROM debian:stretch
RUN apt-get update \
&& apt-get -y --quiet --force-yes upgrade curl iproute2 \
&& apt-get install -y --no-install-recommends ca-certificates gcc g++ make build-essential git iptables-dev libavfilter-dev \
libevent-dev libpcap-dev libxmlrpc-core-c3-dev markdown \
libjson-glib-dev default-libmysqlclient-dev libhiredis-dev libssl-dev \
libcurl4-openssl-dev libavcodec-extra gperf libspandsp-dev libwebsockets-dev\
&& cd /usr/local/src \
&& git clone
https://github.com/sipwise/rtpengine.git \
&& cd rtpengine/daemon \
&& git checkout mr8.5 \
&& make && make install \
&& cp /usr/local/src/rtpengine/daemon/rtpengine /usr/local/bin/rtpengine \
&& rm -Rf /usr/local/src/rtpengine \
&& apt-get purge -y --quiet --force-yes --auto-remove \
ca-certificates gcc g++ make build-essential git markdown \
&& rm -rf /var/lib/apt/* \
&& rm -rf /var/lib/dpkg/* \
&& rm -rf /var/lib/cache/* \
&& rm -Rf /var/log/* \
&& rm -Rf /usr/local/src/* \
&& rm -Rf /var/lib/apt/lists/*
VOLUME ["/tmp"]
EXPOSE 12221/udp
COPY ./entrypoint.sh /entrypoint.sh
COPY ./rtpengine.conf /etc
ENTRYPOINT ["/entrypoint.sh"]
CMD ["rtpengine"]
#!/bin/bash
set -e
PATH=/usr/local/bin:$PATH
LOCAL_IP="$(ip route get 8.8.8.8 | head -1 | cut -d' ' -f7)"
PUBLIC_IP="$(curl
ifconfig.me)";
if [ -n "$PUBLIC_IP" ]; then
MY_IP="$LOCAL_IP"!"$PUBLIC_IP"
else
MY_IP=$LOCAL_IP
fi
sed -i -e "s/MY_IP/$MY_IP/g" /etc/rtpengine.conf
if [ "$1" = 'rtpengine' ]; then
shift
exec rtpengine --config-file /etc/rtpengine.conf "$@"
fi
exec "$@"