mtasa-blue icon indicating copy to clipboard operation
mtasa-blue copied to clipboard

Windows Server support base features

Open Disinterpreter opened this issue 1 year ago • 3 comments

Is your feature request related to a problem? Please describe.

Due to discussion about server OS, i want to remind https://forum.multitheftauto.com/topic/101326-which-os-is-best-for-the-server/#comment-888542 but mta server still not ready to work on Windows. This issue is about adding need features for Windows.

Describe the solution you'd like

  1. Windows service API. The server must work like service (C# example https://learn.microsoft.com/en-us/dotnet/framework/windows-services/walkthrough-creating-a-windows-service-application-in-the-component-designer)
  2. All logs must be written to Windows Event Log system (C# example https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.eventlog.writeentry?view=dotnet-plat-ext-8.0)

Describe alternatives you've considered

No response

Additional context

Why? The service is really convenient for managing. You can set it up automatically restart by schedule, start after OS running, automatically running after crash and so on. Event Log need as a part of it. You should see MTA logs in EventLog system. Without that things, the point that "Windows implementation better" has no point.

Security Policy

  • [X] I have read and understood the Security Policy and this issue is not about a cheat or security vulnerability.

Disinterpreter avatar Jan 16 '24 06:01 Disinterpreter

Everything except events can already be done in Windows.

  • Load when OS starts? Autostart
  • Load when it crashes? Simple batch script iirc you can also set it up in schedules directly without making it a service.

Although it would indeed be a neat feature in some way

TracerDS avatar Jan 16 '24 08:01 TracerDS

Everything except events can already be done in Windows.

* Load when OS starts? Autostart

* Load when it crashes? Simple batch script
  iirc you can also set it up in schedules directly without making it a service.

Although it would indeed be a neat feature in some way

  1. Does autostart work when I not logged on?
  2. workaround, can you write it down to wiki? I suggest dry good thing.

Disinterpreter avatar Jan 16 '24 16:01 Disinterpreter

Everything except events can already be done in Windows.

* Load when OS starts? Autostart

* Load when it crashes? Simple batch script
  iirc you can also set it up in schedules directly without making it a service.

Although it would indeed be a neat feature in some way

  1. Does autostart work when I not logged on?

I dont think so. You have to login for windows to run autostart

  1. workaround, can you write it down to wiki? I suggest dry good thing.

You mean the script? just a simple while true loop will do probably

TracerDS avatar Jan 16 '24 16:01 TracerDS