53 lines
883 B
Bash
Executable File
53 lines
883 B
Bash
Executable File
#!/bin/sh
|
|
|
|
#move to script directory so all relative paths work
|
|
cd "$(dirname "$0")"
|
|
|
|
#includes
|
|
. ./resources/config.sh
|
|
. ./resources/colors.sh
|
|
. ./resources/environment.sh
|
|
|
|
# removes the cd img from the /etc/apt/sources.list file (not needed after base install)
|
|
#sed -i '/cdrom:/d' /etc/apt/sources.list
|
|
|
|
#Update to latest packages
|
|
verbose "Update installed packages"
|
|
pkg upgrade
|
|
|
|
#Update the ports
|
|
portsnap fetch extract
|
|
#portsnap fetch update
|
|
|
|
#PF - Packet Filter
|
|
resources/pf.sh
|
|
|
|
#FusionPBX
|
|
resources/fusionpbx.sh
|
|
|
|
#NGINX web server
|
|
resources/nginx.sh
|
|
|
|
#PHP
|
|
resources/php.sh
|
|
|
|
#Fail2ban
|
|
#resources/fail2ban.sh
|
|
|
|
#FreeSWITCH
|
|
resources/switch.sh
|
|
|
|
#Postgres
|
|
resources/postgres.sh
|
|
|
|
#set the ip address
|
|
server_address=$(hostname -I)
|
|
|
|
#restart services
|
|
service php-fpm restart
|
|
service nginx restart
|
|
service fail2ban restart
|
|
|
|
#add the database schema, user and groups
|
|
resources/finish.sh
|