|
|
|
@ -99,12 +99,12 @@ def handle_message(message)
|
|
|
|
|
when '/srvstop'
|
|
|
|
|
reply = process_command_srvstop(message, command, adm)
|
|
|
|
|
when '/status'
|
|
|
|
|
#reply = process_command_srvstatus(message, command, adm)
|
|
|
|
|
if is_chat_authorized?(message, @auth_chat) || message_from_admin?(message, adm)
|
|
|
|
|
reply = `./scripts/srvstatus #{telnet['host']} #{telnet['port']} #{telnet['pass']}`
|
|
|
|
|
else
|
|
|
|
|
reply = "Refusal: I am not authorized to provide this information here."
|
|
|
|
|
end
|
|
|
|
|
reply = process_command_srvstatus(message, command, adm)
|
|
|
|
|
#if is_chat_authorized?(message, @auth_chat) || message_from_admin?(message, adm)
|
|
|
|
|
# reply = `./scripts/srvstatus #{telnet['host']} #{telnet['port']} #{telnet['pass']}`
|
|
|
|
|
#else
|
|
|
|
|
# reply = "Refusal: I am not authorized to provide this information here."
|
|
|
|
|
#end
|
|
|
|
|
when '/location', '/whereareyou'
|
|
|
|
|
if message_from_admin?(message, adm) || is_chat_authorized?(message, @auth_chat)
|
|
|
|
|
reply = "I am currently located at:\n\nHost: #{`echo $HOSTNAME`}ExtIP: #{`curl myip.contegix.com 2>/dev/null`}"
|
|
|
|
|