fusionpbx-install.sh/debian/resources/switch/package-release.sh

40 lines
1.9 KiB
Bash
Raw Normal View History

2016-04-29 21:24:22 +02:00
#!/bin/sh
apt-get update && apt-get install -y --force-yes curl memcached haveged
USE_UNOFFICIAL_ARM_REPO=0
arch=$(uname -m)
if [ $arch = 'armv7l' ] && [ $USE_UNOFFICIAL_ARM_REPO -eq 1 ]; then
2016-05-09 20:46:16 +02:00
echo "deb http://repo.sip247.com/debian/freeswitch-stable-armhf/ jessie main" > /etc/apt/sources.list.d/freeswitch.list
curl http://repo.sip247.com/debian/sip247.com.gpg.key | apt-key add -
else
2016-05-09 20:46:16 +02:00
echo "deb http://files.freeswitch.org/repo/deb/freeswitch-1.6/ jessie main" > /etc/apt/sources.list.d/freeswitch.list
curl http://files.freeswitch.org/repo/deb/freeswitch-1.6/key.gpg | apt-key add -
fi
2016-04-29 21:24:22 +02:00
apt-get update && apt-get install -y --force-yes freeswitch-all freeswitch-all-dbg gdb
#apt-get remove freeswitch-all freeswitch-all-dbg
#rm /etc/apt/sources.list.d/freeswitch.list
#set the file permissions
chown -R freeswitch:freeswitch /var/lib/freeswitch
2016-04-29 21:24:22 +02:00
chmod -R g+s /var/lib/freeswitch
setfacl -R -m u:www-data:rwx,g:www-data:rwx /var/lib/freeswitch
setfacl -R -d -m u:www-data:rwx,g:www-data:rwx /var/lib/freeswitch
2016-04-29 21:24:22 +02:00
chown -R freeswitch:freeswitch /usr/share/freeswitch
2016-04-29 21:24:22 +02:00
chmod -R g+s /usr/share/freeswitch
setfacl -R -m u:www-data:rwx,g:www-data:rwx /usr/share/freeswitch
setfacl -R -d -m u:www-data:rwx,g:www-data:rwx /usr/share/freeswitch
2016-04-29 21:24:22 +02:00
chown -R freeswitch:freeswitch /etc/freeswitch
2016-04-29 21:24:22 +02:00
chmod -R g+s /etc/freeswitch
setfacl -R -m u:www-data:rwx,g:www-data:rwx /etc/freeswitch
setfacl -R -d -m u:www-data:rwx,g:www-data:rwx /etc/freeswitch
2016-04-29 21:24:22 +02:00
chown -R freeswitch:freeswitch /var/log/freeswitch
setfacl -R -m u:www-data:rwx,g:www-data:rwx /var/log/freeswitch
setfacl -R -d -m u:www-data:rwx,g:www-data:rwx /var/log/freeswitch
2016-04-29 21:24:22 +02:00
chown -R freeswitch:freeswitch /usr/share/freeswitch/sounds
2016-04-29 21:24:22 +02:00
chmod -R g+s /usr/share/freeswitch/sounds
setfacl -R -m u:www-data:rwx,g:www-data:rwx /usr/share/freeswitch/sounds
setfacl -R -d -m u:www-data:rwx,g:www-data:rwx /usr/share/freeswitch/sounds