1 (edited by ghost 2010-12-08 18:06:16)

Topic: [SUGGESTION] Telnet support

Hello guys,

after reading this topic about a way to monitor and administrate servers, I realized there is the need for administration tools for teeworlds. There are already solutions for this. For example, a lot of server hosters have created a web interface, which allows the user to create servers with different configuration files, and to terminate or restart those servers. Also tools like Teeworlds Server Manager have been created to simplify the process of managing server on your local computer.

However, these tools lack one major aspect, which is the possibility to control the server while it is running. This is due to the fact, that at the moment it is not possible to communicate with the teeworlds server from the outside in another way than connecting to it is a usual client. Of course creating a program which connects to the server and then to the rcon console as a usual client and then provides a user interface or an API or whatever would be a possible solution, but there are several major disadvantages to this method:

  • Connecting to the server is not possible if all 16 slots are already used

  • While administrating, there are only 15 slots available for players

  • A lot of unnecessary data is sent to both server and administration client (which means waste of bandwidth)

All of these issues can be avoided be providing a different method to connect to the server, for example support for telnet. Also, by using this (or a similar) method, It would be easy for the community to write their own administrating programs, interfaces or bots, without having to know too much about the teeworlds protocol itself, which would probably cause a lot of programs like i mentioned before to be created, and those that already exist would probably be enhanced. I believe this would all result in a strongly improved usability of the teeworlds server.

There is already an attempt to implement telnet support, but it was done for a much older version of teeworlds, and it had some problems and thus never got included in the official teeworlds code. You can find the corresponding topic here.

Matricks wrote:

I've had this idea for a while but not done it because lack of time... as usual....

This statement made by Matricks as an answer to the topic supports my opinion that this feature should get implemented.
However the code supplied in the patch files in this topic would need to be redone completely, because, as mentioned before it was created for an older version (before the code was refactored), and because the issues this attempt has would need to be solved.

I hope I was successful in explaining why this feature is needed in teeworlds, and I am looking forward to reading your opinions about this topic.

Kind regards,

ghost

2

Re: [SUGGESTION] Telnet support

I had this idea a long time ago, but never found the motivation to do it.

I wanted to make some kind of webadmin tool.
The server would spawn another thread (or maybe not, ...) which would listen on a defined port, and serve HTTP pages. Password protected of course (could be the rcon password, or something else).
Because I didn't want to redevelop the HTTP protocol, I did some research and found a library that might be useful: libmicrohttpd.

It's sure more work to develop than a simple telnet rcon, but easier to use if correctly done.
One would not have to remember lots of server commands to achieve what he/she wants, but just have to click some links or buttons. And you can still have a page where you can enter good ol' server commands.

I also thought about a system of "template" pages (let's call it this way), which would allow to easily add a page to the WebAdmin by simply adding a text file. Then mod authors could provide a template to be used with the WebAdmin, without having to provide two versions of their mod (one with WebAdmin support and one without).
But that template system is one thing to do AFTER doing the main part: serving HTTP pages to manage the server in real-time.

spl0k, aka Al`. From the HuH clan.
Noobing pwns since 01/01/1970.
TeeViewer - TeeComp

3 (edited by erd 2010-12-10 21:42:00)

Re: [SUGGESTION] Telnet support

spl0k, I don't think it is a good idea to implement a whole webserver (but the idea of a web administration tool is good!). There are already existing very good webservers and tools for web development (including template engines).
A simple API would just be fine, this way it would be possible to write much more tools for administration (website, "normal" gui interface, ...) or even let the administration tool run on another server then the tw server itself and so not produce to much load and therefore lags.

4

Re: [SUGGESTION] Telnet support

Are there anymore opinions about that? Should I maybe create an issue for that on github?