From c8227e4b11365ce9de5385f6813c9cd3ea2d128f Mon Sep 17 00:00:00 2001 From: Markus Frindt Date: Wed, 17 Jul 2024 14:34:37 +0200 Subject: [PATCH] Add command for g711 codes, but PCMA is prioritized (#30) * Add command for g711 codes, but PCMA is prioritized * update gitignore * update command * Apply suggestions from PR review --------- Co-authored-by: Markus Frindt --- .gitignore | 2 ++ entrypoint.sh | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/.gitignore b/.gitignore index e43b0f9..29bb3fc 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ .DS_Store + +.vscode \ No newline at end of file diff --git a/entrypoint.sh b/entrypoint.sh index d387b3b..59e97f7 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -17,6 +17,12 @@ while :; do shift ;; + --g711-only-alaw-preferred) + sed -i -e "s/global_codec_prefs=.*\"/global_codec_prefs=PCMA,PCMU\"/g" /usr/local/freeswitch/conf/vars.xml + sed -i -e "s/outbound_codec_prefs=.*\"/outbound_codec_prefs=PCMA,PCMU\"/g" /usr/local/freeswitch/conf/vars.xml + shift + ;; + -s|--sip-port) if [ -n "$2" ]; then sed -i -e "s/sip_port=[[:digit:]]\+/sip_port=$2/g" /usr/local/freeswitch/conf/vars_diff.xml