Skip to content

Instantly share code, notes, and snippets.

@Deliquescence
Last active November 27, 2025 05:49
Show Gist options
  • Select an option

  • Save Deliquescence/fd0b374dcb8461a8261d19d0641043b7 to your computer and use it in GitHub Desktop.

Select an option

Save Deliquescence/fd0b374dcb8461a8261d19d0641043b7 to your computer and use it in GitHub Desktop.
Minecraft server systemd
[Unit]
Description=Minecraft Server
After=network.target
[Service]
Type=simple
Restart=always
RestartSec=30
TimeoutSec=120
User=minecraft
Group=minecraft
ExecStart=/home/minecraft/Minecraft/start.sh
[Install]
WantedBy=multi-user.target
[Unit]
Description=Start minecraft server after delay
[Timer]
OnBootSec=30sec
OnActiveSec=30sec
AccuracySec=1s
Unit=minecraft.service
[Install]
WantedBy=timers.target
#!/bin/sh
cd "/home/minecraft/Minecraft/Server"
source "/home/minecraft/Minecraft/Server/run.sh"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment