function to remove mumble
This commit is contained in:
parent
7666e778e4
commit
94641a370c
|
@ -37,6 +37,26 @@ VOIP_PORT=64738
|
||||||
VOIP_DATABASE="mumble-server.sqlite"
|
VOIP_DATABASE="mumble-server.sqlite"
|
||||||
VOIP_CONFIG_FILE="mumble-server.ini"
|
VOIP_CONFIG_FILE="mumble-server.ini"
|
||||||
|
|
||||||
|
function remove_mumble {
|
||||||
|
if !grep -Fxq "install_mumble" $COMPLETION_FILE; then
|
||||||
|
if ! grep -Fxq "install_voip" $COMPLETION_FILE; then
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
apt-get -y remove --purge mumble-server
|
||||||
|
iptables -D INPUT -p udp --dport $VOIP_PORT -j ACCEPT
|
||||||
|
iptables -D INPUT -p tcp --dport $VOIP_PORT -j ACCEPT
|
||||||
|
function_check save_firewall_settings
|
||||||
|
save_firewall_settings
|
||||||
|
if [ -f /etc/mumble-server.ini ]; then
|
||||||
|
rm /etc/mumble-server.ini
|
||||||
|
fi
|
||||||
|
sed -i '/install_mumble/d' $COMPLETION_FILE
|
||||||
|
sed -i '/install_voip/d' $COMPLETION_FILE
|
||||||
|
sed -i '/configure_firewall_for_voip/d' $COMPLETION_FILE
|
||||||
|
sed -i '/VoIP /d' $COMPLETION_FILE
|
||||||
|
}
|
||||||
|
|
||||||
function get_voip_server_password {
|
function get_voip_server_password {
|
||||||
if [ -f /home/$MY_USERNAME/README ]; then
|
if [ -f /home/$MY_USERNAME/README ]; then
|
||||||
if grep -q "VoIP server password" /home/$MY_USERNAME/README; then
|
if grep -q "VoIP server password" /home/$MY_USERNAME/README; then
|
||||||
|
|
Loading…
Reference in New Issue