diff options
author | Iordan Iordanov <iiordanov@gmail.com> | 2011-12-01 22:14:14 +0000 |
---|---|---|
committer | Iordan Iordanov <iiordanov@gmail.com> | 2011-12-01 22:14:14 +0000 |
commit | f932acab1040123bbf782c687023f307567883ae (patch) | |
tree | 802abb55375255fcb1f647fd66367351eacac75b /applications/luci-pbx/root | |
parent | 6f46d97b76adc5f63cf9fe6fa7511d492fed6efe (diff) |
1) Added sounds needed for authentication app.
2) Added license and attribution for sounds
3) Added linking sounds into the asterisk sounds directory.
Diffstat (limited to 'applications/luci-pbx/root')
-rwxr-xr-x | applications/luci-pbx/root/etc/init.d/pbx-asterisk | 24 | ||||
-rw-r--r-- | applications/luci-pbx/root/etc/pbx-asterisk/sounds/agent-alreadyon.gsm | bin | 0 -> 8943 bytes | |||
-rw-r--r-- | applications/luci-pbx/root/etc/pbx-asterisk/sounds/auth-thankyou.gsm | bin | 0 -> 1353 bytes |
3 files changed, 23 insertions, 1 deletions
diff --git a/applications/luci-pbx/root/etc/init.d/pbx-asterisk b/applications/luci-pbx/root/etc/init.d/pbx-asterisk index 5812b3a738..0c41833cfc 100755 --- a/applications/luci-pbx/root/etc/init.d/pbx-asterisk +++ b/applications/luci-pbx/root/etc/init.d/pbx-asterisk @@ -31,9 +31,12 @@ ASTUSER=nobody ASTGROUP=nogroup ASTDIRSRECURSIVE="/var/run/asterisk /var/log/asterisk /var/spool/asterisk" ASTDIRS="/usr/lib/asterisk" +ASTSOUNDSDIR="/usr/lib/asterisk/sounds" TEMPLATEDIR=/etc/${MODULENAME}-asterisk +PBXSOUNDSDIR=$TEMPLATEDIR/sounds VMTEMPLATEDIR=/etc/${MODULENAME}-voicemail +VMSOUNDSDIR=$VMTEMPLATEDIR/sounds ASTERISKDIR=/etc/asterisk WORKDIR=/tmp/$MODULENAME.$$ MD5SUMSFILE=/tmp/$MODULENAME-sums.$$ @@ -575,6 +578,22 @@ pbx_cook_rtp_template() sed "s/|RTPEND|/$rtpend/" > $WORKDIR/rtp.conf } +# Links any sound files found in $PBXSOUNDSDIR and $VMSOUNDSDIR +# into $ASTSOUNDSDIR for use by Asterisk. Does not overwrite files. +pbx_link_sounds() +{ + mkdir -p $ASTSOUNDSDIR + + for dir in $PBXSOUNDSDIR $VMSOUNDSDIR ; do + if [ -d $dir ] ; then + for f in $dir/* ; do + ln -s $f $ASTSOUNDSDIR 2>/dev/null + done + fi + done +} + + # Makes sure the ownership of specified directories is proper. pbx_fix_ownership() { @@ -667,13 +686,16 @@ start() { # Prepare voicemail config. config_unset config_load ${MODULENAME}-voicemail - pbx_configure_voicemail + pbx_configure_voicemail # Assemble the configuration, and copy changed files over. config_unset config_load ${MODULENAME}-advanced pbx_assemble_and_copy_config + # Link sound files + pbx_link_sounds + # Enforce ownership of specified files and directories. pbx_fix_ownership } diff --git a/applications/luci-pbx/root/etc/pbx-asterisk/sounds/agent-alreadyon.gsm b/applications/luci-pbx/root/etc/pbx-asterisk/sounds/agent-alreadyon.gsm Binary files differnew file mode 100644 index 0000000000..83fe27ecfa --- /dev/null +++ b/applications/luci-pbx/root/etc/pbx-asterisk/sounds/agent-alreadyon.gsm diff --git a/applications/luci-pbx/root/etc/pbx-asterisk/sounds/auth-thankyou.gsm b/applications/luci-pbx/root/etc/pbx-asterisk/sounds/auth-thankyou.gsm Binary files differnew file mode 100644 index 0000000000..93f936d1a0 --- /dev/null +++ b/applications/luci-pbx/root/etc/pbx-asterisk/sounds/auth-thankyou.gsm |