cleanup of the deb pkg ver of the install
This commit is contained in:
parent
de886e6c98
commit
44bc066a26
|
|
@ -1,7 +1,8 @@
|
||||||
#######################################
|
#######################################
|
||||||
#Setup Main debian repo for right pkgs
|
# Setup Main debian repo for right pkgs
|
||||||
|
# This makes the repos use the repo local
|
||||||
|
# to theusers region
|
||||||
#######################################
|
#######################################
|
||||||
echo "installing jessie release repo"
|
|
||||||
cat > "/etc/apt/sources.list" << DELIM
|
cat > "/etc/apt/sources.list" << DELIM
|
||||||
deb http://httpredir.debian.org/debian/ jessie main contrib non-free
|
deb http://httpredir.debian.org/debian/ jessie main contrib non-free
|
||||||
deb-src http://httpredir.debian.org/debian/ jessie main contrib non-free
|
deb-src http://httpredir.debian.org/debian/ jessie main contrib non-free
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
#Select Optional Addon Pkgs
|
||||||
|
######################################################################################################################
|
||||||
adminer="y" # : integrated for an administrator in the superadmin group to enable easy database access
|
adminer="y" # : integrated for an administrator in the superadmin group to enable easy database access
|
||||||
backup="y" # : pbx backup module. backup sqlite db / configs/ logs
|
backup="y" # : pbx backup module. backup sqlite db / configs/ logs
|
||||||
call_broadcast="n" # : Create a recording and select one or more groups to have the system call and play the recording
|
call_broadcast="n" # : Create a recording and select one or more groups to have the system call and play the recording
|
||||||
|
|
@ -11,10 +13,8 @@ fax="y" # : fusionpbx send/recieve faxes service
|
||||||
fifo="n" # : first in first out call queues system
|
fifo="n" # : first in first out call queues system
|
||||||
services="n" # : allows interaction with the processes running on your server
|
services="n" # : allows interaction with the processes running on your server
|
||||||
traffic_graph="n" # : php graph for monitoing the network interface traffic
|
traffic_graph="n" # : php graph for monitoing the network interface traffic
|
||||||
|
#####################################################################################################################
|
||||||
|
|
||||||
###########################
|
|
||||||
#Optional APP PKGS installs
|
|
||||||
###########################
|
|
||||||
if [[ $adminer == "y" ]]; then
|
if [[ $adminer == "y" ]]; then
|
||||||
apt-get -y --force-yes install fusionpbx-app-adminer
|
apt-get -y --force-yes install fusionpbx-app-adminer
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
|
|
@ -42,7 +42,7 @@ cp -rp "$fs_dflt_conf_dir"/vanilla/* "/etc/fusionpbx"
|
||||||
########################################
|
########################################
|
||||||
#fix ownership of files for freeswitch
|
#fix ownership of files for freeswitch
|
||||||
########################################
|
########################################
|
||||||
chown -R freeswitch:www-data "/etc/fusionpbx"
|
chown -R www-data:freeswitch "/etc/fusionpbx"
|
||||||
|
|
||||||
##################################################
|
##################################################
|
||||||
#configuring freeswitch to start with new layout.
|
#configuring freeswitch to start with new layout.
|
||||||
|
|
@ -56,14 +56,13 @@ CONFDIR="/etc/fusionpbx"
|
||||||
# Options to control locations of files:
|
# Options to control locations of files:
|
||||||
fs_conf="/etc/fusionpbx"
|
fs_conf="/etc/fusionpbx"
|
||||||
fs_db="/var/lib/freeswitch/db"
|
fs_db="/var/lib/freeswitch/db"
|
||||||
fs_imgs="/var/lib/fusionpbx/images"
|
|
||||||
fs_log="/var/log/freeswitch"
|
fs_log="/var/log/freeswitch"
|
||||||
fs_recordings="/var/lib/fusionpbx/recordings"
|
fs_recordings="/var/lib/fusionpbx/recordings"
|
||||||
fs_run="/var/run/freeswitch"
|
fs_run="/run/freeswitch"
|
||||||
fs_scripts="/var/lib/fusionpbx/scripts"
|
fs_scripts="/var/lib/fusionpbx/scripts"
|
||||||
fs_storage="/var/lib/fusionpbx/storage"
|
fs_storage="/var/lib/fusionpbx/storage"
|
||||||
fs_usr=freeswitch
|
fs_usr=freeswitch
|
||||||
fs_grp=\$fs_usr
|
fs_grp=www-data
|
||||||
#
|
#
|
||||||
#These are the optional arguments you can pass to freeswitch: (add options to fs_options line)
|
#These are the optional arguments you can pass to freeswitch: (add options to fs_options line)
|
||||||
# -nf -- no forking
|
# -nf -- no forking
|
||||||
|
|
@ -86,10 +85,9 @@ fs_grp=\$fs_usr
|
||||||
# -nc -- do not output to a console and background
|
# -nc -- do not output to a console and background
|
||||||
# -ncwait -- do not output to a console and background but wait until the system is ready before exiting (implies -nc)
|
# -ncwait -- do not output to a console and background but wait until the system is ready before exiting (implies -nc)
|
||||||
# -c -- output to a console and stay in the foreground
|
# -c -- output to a console and stay in the foreground
|
||||||
fs_options="-nc -rp -reincarnate"
|
|
||||||
#
|
#
|
||||||
# Reads in the arguments into 1 line command
|
# Reads in the arguments into 1 line command
|
||||||
DAEMON_ARGS="-u \$fs_usr -g \$fs_grp -conf \$fs_conf -db \$fs_db -images \$fs_images -log \$fs_log -scripts \$fs_scripts -run \$fs_run -storage \$fs_storage -recordings \$fs_recordings \$fs_options"
|
DAEMON_ARGS="-nc -rp -reincarnate"
|
||||||
DELIM
|
DELIM
|
||||||
|
|
||||||
#################################################################
|
#################################################################
|
||||||
|
|
|
||||||
|
|
@ -1,39 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
#send a message
|
|
||||||
echo "Install PostgreSQL"
|
|
||||||
|
|
||||||
#generate a random password
|
|
||||||
password=$(dd if=/dev/urandom bs=1 count=20 2>/dev/null | base64)
|
|
||||||
|
|
||||||
#Postgres
|
|
||||||
echo "Install PostgreSQL and create the database and users\n"
|
|
||||||
apt-get install -y --force-yes sudo postgresql
|
|
||||||
|
|
||||||
#systemd
|
|
||||||
/bin/systemctl restart postgresql
|
|
||||||
|
|
||||||
#init.d
|
|
||||||
#/usr/sbin/service postgresql restart
|
|
||||||
|
|
||||||
#add the databases, users and grant permissions to them
|
|
||||||
sudo -u postgres psql -c "CREATE DATABASE fusionpbx";
|
|
||||||
sudo -u postgres psql -c "CREATE DATABASE freeswitch";
|
|
||||||
sudo -u postgres psql -c "CREATE ROLE fusionpbx WITH SUPERUSER LOGIN PASSWORD '$password';"
|
|
||||||
sudo -u postgres psql -c "CREATE ROLE freeswitch WITH SUPERUSER LOGIN PASSWORD '$password';"
|
|
||||||
sudo -u postgres psql -c "GRANT ALL PRIVILEGES ON DATABASE fusionpbx to fusionpbx;"
|
|
||||||
sudo -u postgres psql -c "GRANT ALL PRIVILEGES ON DATABASE freeswitch to fusionpbx;"
|
|
||||||
sudo -u postgres psql -c "GRANT ALL PRIVILEGES ON DATABASE freeswitch to freeswitch;"
|
|
||||||
#ALTER USER fusionpbx WITH PASSWORD 'newpassword';
|
|
||||||
|
|
||||||
#set the ip address
|
|
||||||
server_address=$(hostname -I)
|
|
||||||
|
|
||||||
#Show database password
|
|
||||||
echo ""
|
|
||||||
echo ""
|
|
||||||
echo "PostgreSQL"
|
|
||||||
echo " Database name: fusionpbx"
|
|
||||||
echo " Database username: fusionpbx"
|
|
||||||
echo " Database password: $password"
|
|
||||||
echo ""
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
#Selet What Phone Provision System to Install
|
#Selet What Phone Provision System to Install
|
||||||
|
###############################################################################
|
||||||
aastra="n" # : phone provisioning tool & templates for aastra phones
|
aastra="n" # : phone provisioning tool & templates for aastra phones
|
||||||
atcom="n" # : phone provisioning tool & templates for atcom phones
|
atcom="n" # : phone provisioning tool & templates for atcom phones
|
||||||
cisco="n" # : phone provisioning tool & templates for cisco phones
|
cisco="n" # : phone provisioning tool & templates for cisco phones
|
||||||
|
|
@ -11,7 +11,7 @@ panasonic="n" # : phone provisioning tool & templates for panasonic phones
|
||||||
polycom="n" # : phone provisioning tool & templates for polycom phones
|
polycom="n" # : phone provisioning tool & templates for polycom phones
|
||||||
snom="n" # : provisioning tool & templates for snom phones
|
snom="n" # : provisioning tool & templates for snom phones
|
||||||
yealink="n" # : phone provisioning tool & templates for yealink phones
|
yealink="n" # : phone provisioning tool & templates for yealink phones
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
if [[ $aastra == "y" ]]; then
|
if [[ $aastra == "y" ]]; then
|
||||||
apt-get -y --force-yes install fusionpbx-app-devices fusionpbx-app-provision fusionpbx-provisioning-template-aastra && mkdir -p /etc/fusionpbx/resources/templates/provision && cp -rp /usr/share/examples/fusionpbx/resources/templates/provision/aastra /etc/fusionpbx/resources/templates/provision/
|
apt-get -y --force-yes install fusionpbx-app-devices fusionpbx-app-provision fusionpbx-provisioning-template-aastra && mkdir -p /etc/fusionpbx/resources/templates/provision && cp -rp /usr/share/examples/fusionpbx/resources/templates/provision/aastra /etc/fusionpbx/resources/templates/provision/
|
||||||
|
|
|
||||||
|
|
@ -29,17 +29,16 @@ apt-get update && apt-get -y install --force-yes sqlite3 unixodbc uuid memcached
|
||||||
|
|
||||||
#Freeswitch Pkgs
|
#Freeswitch Pkgs
|
||||||
apt-get -y install --force-yes libfreeswitch1 freeswitch freeswitch-mod-curl freeswitch-systemd freeswitch-mod-db freeswitch-doc \
|
apt-get -y install --force-yes libfreeswitch1 freeswitch freeswitch-mod-curl freeswitch-systemd freeswitch-mod-db freeswitch-doc \
|
||||||
freeswitch-mod-distributor freeswitch-mod-dptools freeswitch-mod-enum freeswitch-mod-esf freeswitch-mod-esl \
|
freeswitch-mod-distributor freeswitch-mod-dptools freeswitch-mod-enum freeswitch-mod-esf freeswitch-mod-esl freeswitch-mod-expr \
|
||||||
freeswitch-mod-expr freeswitch-mod-fsv freeswitch-mod-hash freeswitch-mod-memcache freeswitch-mod-portaudio \
|
freeswitch-mod-fsv freeswitch-mod-hash freeswitch-mod-memcache freeswitch-mod-portaudio freeswitch-mod-portaudio-stream \
|
||||||
freeswitch-mod-portaudio-stream freeswitch-mod-spandsp freeswitch-mod-spy freeswitch-mod-translate \
|
freeswitch-mod-spandsp freeswitch-mod-spy freeswitch-mod-translate freeswitch-mod-valet-parking freeswitch-mod-flite \
|
||||||
freeswitch-mod-valet-parking freeswitch-mod-flite freeswitch-mod-pocketsphinx freeswitch-mod-tts-commandline \
|
freeswitch-mod-pocketsphinx freeswitch-mod-tts-commandline freeswitch-mod-dialplan-xml freeswitch-mod-loopback freeswitch-mod-sofia \
|
||||||
freeswitch-mod-dialplan-xml freeswitch-mod-loopback freeswitch-mod-sofia freeswitch-mod-event-multicast \
|
freeswitch-mod-event-multicast freeswitch-mod-event-socket freeswitch-mod-local-stream freeswitch-mod-native-file freeswitch-mod-sndfile \
|
||||||
freeswitch-mod-event-socket freeswitch-mod-local-stream freeswitch-mod-native-file freeswitch-mod-sndfile \
|
freeswitch-mod-tone-stream freeswitch-mod-lua freeswitch-mod-console freeswitch-mod-logfile freeswitch-mod-syslog freeswitch-mod-say-en \
|
||||||
freeswitch-mod-tone-stream freeswitch-mod-lua freeswitch-mod-console freeswitch-mod-logfile freeswitch-mod-syslog \
|
freeswitch-mod-posix-timer freeswitch-mod-timerfd freeswitch-mod-xml-cdr freeswitch-mod-shout freeswitch-mod-xml-curl freeswitch-mod-xml-rpc \
|
||||||
freeswitch-mod-say-en freeswitch-mod-posix-timer freeswitch-mod-timerfd freeswitch-mod-xml-cdr freeswitch-mod-shout\
|
freeswitch-conf-vanilla freeswitch-mod-vlc freeswitch-mod-verto freeswitch-mod-sms freeswitch-timezones freeswitch-mod-bert \
|
||||||
freeswitch-mod-xml-curl freeswitch-mod-xml-rpc freeswitch-conf-vanilla freeswitch-mod-vlc freeswitch-mod-verto \
|
freeswitch-mod-basic freeswitch-mod-lcr freeswitch-mod-rtc freeswitch-mod-commands freeswitch-mod-cdr-csv freeswitch-mod-png
|
||||||
freeswitch-mod-sms freeswitch-timezones freeswitch-mod-bert freeswitch-mod-basic freeswitch-mod-lcr freeswitch-mod-rtc \
|
freeswitch-mod-g723.1 freeswitch-mod-amr freeswitch-mod-b64 freeswitch-mod-opus freeswitch-mod-httapi freeswitch-mod-voicemail
|
||||||
freeswitch-mod-commands freeswitch-mod-cdr-csv
|
|
||||||
|
|
||||||
#setup language / sound files for use
|
#setup language / sound files for use
|
||||||
#if [[ $freeswitch_sounds_language == "en-ca" ]]; then
|
#if [[ $freeswitch_sounds_language == "en-ca" ]]; then
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue