LinuxGSM icon indicating copy to clipboard operation
LinuxGSM copied to clipboard

fix(ts3server): Monitor command fails, if query_ip is set to a loopback IP

Open drantor opened this issue 4 years ago • 0 comments

Description

Fix monitoring failing and restarting the teamspeak server, if the query interface is bound to a loopback IP. I didn't want to remove the logic for filtering loopback IPs, so I just added fetching the query_ip from the ts3server.ini and using that one as queryips in check_ip which then will be used in command_monitor. I also added the other configurable teamspeak IPs as variables, even if they currently have no use.

Background

I don't want remote users to connect to the teamspeak query interface, so I bound it to 127.0.0.1. With the 21.5.0 Release ts3 got added to info_game and the monitor command is now checking the query port, but check_ip is filtering 127.0.0-IPs, so the monitor command was failing for me every time. I'm not 100% certain that this is the cause but it started after the update-lgsm cron had run, and this are the only changes where I could see a effect on ts3server.

Type of change

  • [X] Bug fix (a change which fixes an issue).
  • [ ] New feature (change which adds functionality).
  • [ ] New Server (new server added).
  • [ ] Refactor (restructures existing code).
  • [ ] Comment update (typo, spelling, explanation, examples, etc).

Checklist

PR will not be merged until all steps are complete.

  • [ ] This pull request links to an issue.
  • [X] This pull request uses the develop branch as its base.
  • [X] This pull request Subject follows the Conventional Commits standard.
  • [X] This code follows the style guidelines of this project.
  • [X] I have performed a self-review of my code.
  • [X] I have checked that this code is commented where required.
  • [X] I have provided a detailed with enough description of this PR.
  • [X] I have checked If documentation needs updating.

Documentation

If documentation does need updating either update it by creating a PR (preferred) or request a documentation update.

  • User docs: https://github.com/GameServerManagers/LinuxGSM-Docs
  • Dev docs: https://github.com/GameServerManagers/LinuxGSM-Dev-Docs

Thank you for your Pull Request!

drantor avatar Jan 01 '22 22:01 drantor