|
@@ -5,12 +5,10 @@
|
|
|
# Website: https://linuxgsm.com
|
|
# Website: https://linuxgsm.com
|
|
|
# Description: Changes TS3 serveradmin password.
|
|
# Description: Changes TS3 serveradmin password.
|
|
|
|
|
|
|
|
-fn_commandname(){
|
|
|
|
|
- commandname="CHANGE-PASSWORD"
|
|
|
|
|
- commandaction="Changing password"
|
|
|
|
|
- functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
|
|
|
|
|
-}
|
|
|
|
|
-fn_commandname
|
|
|
|
|
|
|
+commandname="CHANGE-PASSWORD"
|
|
|
|
|
+commandaction="Changing password"
|
|
|
|
|
+functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")"
|
|
|
|
|
+fn_firstcommand_set
|
|
|
|
|
|
|
|
fn_serveradmin_password_prompt(){
|
|
fn_serveradmin_password_prompt(){
|
|
|
fn_print_header
|
|
fn_print_header
|
|
@@ -31,7 +29,7 @@ fn_serveradmin_password_set(){
|
|
|
ts3serverpass="1"
|
|
ts3serverpass="1"
|
|
|
exitbypass="1"
|
|
exitbypass="1"
|
|
|
command_start.sh
|
|
command_start.sh
|
|
|
- fn_commandname
|
|
|
|
|
|
|
+ fn_firstcommand_reset
|
|
|
fn_print_ok_nl "New password applied"
|
|
fn_print_ok_nl "New password applied"
|
|
|
fn_script_log_pass "New ServerAdmin password applied"
|
|
fn_script_log_pass "New ServerAdmin password applied"
|
|
|
}
|
|
}
|
|
@@ -43,16 +41,16 @@ if [ "${status}" != "0" ]; then
|
|
|
# Stop any running server.
|
|
# Stop any running server.
|
|
|
exitbypass="1"
|
|
exitbypass="1"
|
|
|
command_stop.sh
|
|
command_stop.sh
|
|
|
- fn_commandname
|
|
|
|
|
|
|
+ fn_firstcommand_reset
|
|
|
fn_serveradmin_password_set
|
|
fn_serveradmin_password_set
|
|
|
parms="serveradmin_password=\"${newpassword}\" inifile=\"${servercfgfullpath}\" > /dev/null 2>&1"
|
|
parms="serveradmin_password=\"${newpassword}\" inifile=\"${servercfgfullpath}\" > /dev/null 2>&1"
|
|
|
ts3serverpass="0"
|
|
ts3serverpass="0"
|
|
|
command_restart.sh
|
|
command_restart.sh
|
|
|
- fn_commandname
|
|
|
|
|
|
|
+ fn_firstcommand_reset
|
|
|
else
|
|
else
|
|
|
fn_serveradmin_password_set
|
|
fn_serveradmin_password_set
|
|
|
command_stop.sh
|
|
command_stop.sh
|
|
|
- fn_commandname
|
|
|
|
|
|
|
+ fn_firstcommand_reset
|
|
|
fi
|
|
fi
|
|
|
|
|
|
|
|
core_exit.sh
|
|
core_exit.sh
|