Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

systemd auto install #2145

Open
dgibbs64 opened this issue Jan 4, 2019 · 4 comments · May be fixed by #3125
Open

systemd auto install #2145

dgibbs64 opened this issue Jan 4, 2019 · 4 comments · May be fixed by #3125

Comments

@dgibbs64
Copy link
Member

dgibbs64 commented Jan 4, 2019

Basic info
Game: LinuxGSM general
Distro: Systemd supported distros

Is your feature request related to a problem? Please describe.
Systemd is the standard way of managing services and starting on boot. However, it is not "simple" to use for a standard admin. It would be a good idea for convenience for the LinuxGSM script to install systemd script specific to itself and be able to also remove the systemd script as well.

Describe the solution you'd like
Automated installation of systemd using a new LinuxGSM command

Describe alternatives you've considered
The admin manually adding the script

@dgibbs64 dgibbs64 added the type: feature request New feature or request label Jan 4, 2019
@dgibbs64
Copy link
Member Author

dgibbs64 commented Jan 4, 2019

relates to GameServerManagers/LinuxGSM-Docs#3

@Stormwind99
Copy link

Stormwind99 commented Apr 24, 2019

I perhaps have some work to better support systemd including multiple server instances per game.

See https://github.com/Stormwind99/LinuxGSM/tree/better-for-systemd

Here is my use case (and thus current test case) for Minecraft, where I have multiple Minecraft servers running. The fork branch above creates a pid file for each server used below in the systemd minecraft.service file, and also makes a separate tmux server instance for each game server instance (so systemd isn't confused by a different slice's process (from another game instance) starting the current slice's process.

[Unit]
Description=Minecraft Server %I
After=network-online.target
Wants=network-online.target

[Service]
Type=forking
User=minecraft
WorkingDirectory=/var/games/minecraft/server/server-%i
ExecStart=/var/games/minecraft/server/server-%i/mcserver-%i start
ExecStop=/var/games/minecraft/server/server-%i/mcserver-%i stop
Restart=on-failure
PIDFile=/var/games/minecraft/server/server-%i/.mcserver-%i.pid

[Install]
WantedBy=multi-user.target
GitHub
Linux Game Server Managers_. Contribute to Stormwind99/LinuxGSM development by creating an account on GitHub.

@legendofmiracles
Copy link

very basic implementation in: #3152

@AndrewSav
Copy link

What happened with 3125?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants