Put your minecraft server to rest, while SleepingServerStarter is watching! Save power, save the world!
[Tutorial Video](https://youtu.be/WqvQISpr6-s) | [Based on minecraft-protocol](https://github.com/PrismarineJS/node-minecraft-protocol) | [Based on JSPrismarine](https://github.com/JSPrismarine/JSPrismarine) | [Original idea](https://github.com/tustin2121/MCSignOnDoor)
Works better with EmptyServerStopper, a plugin that automatically stops your server after a definied amount of time
There are multiple ways to run SleepingServerStarter:
spigot.jar
, paper.jar
, etc...)chmod +x mcsleepingserverstarter-linux-x64
if you can't run the executablenpm ci
npm start
SleepingServerStarter is available as a Docker image: ghcr.io/vincss/mcsleepingserverstarter
It supports both x64 and arm64 host system architectures.
For detailed examples and instructions for setup via Docker, see the wiki page here.
If you're using PufferPanel, you can import this template as JSON to use Paper Spigot with Sleeping Server Starter via PufferPanel
If you're using Pterodactyl, you can import this egg as JSON to use Paper Spigot with Sleeping Server Starter OR you can also import this egg as JSON to use Vanilla Minecraft with Sleeping Server Starter on Pterodactyl
Pterodactyl can be installed via Unofficial pterodactyl-installer
Note: If running from binaries, the settings file will be created after the first execution in the same folder as the executable
Setting | Description | Default value |
---|---|---|
serverName |
The name of your server. You can specify colour codes by using the Β§ prefix (Does not work on Bedrock) |
"SleepingServer, waiting for his prince..." |
serverMOTD |
The MOTD to display for Minecraft Servers. You can specify colour codes just as you can for serverName . Defaults to serverName if not set. (Still does not work on Bedrock) |
Same as serverName |
serverPort |
The port of your Java Edition server (0 to disable) | 25565 |
bedrockPort |
The port of your Bedrock Edition server (0 to disable) | 19132 |
loginMessage |
Message shown when the server is off and someone is trying to connect | "...Waking server up, come back in a minute..." |
serverOnlineMode |
Check if players has premium accounts | true |
maxPlayers |
Maximum amount of players | 20 |
useNativeFiles |
Use Minecraft server.properties to overwrite serverPort , maxPlayers , serverOnlineMode , useWhitelistFile , and useBlacklistFiles properties |
false |
webPort |
Port for the Web-Gui | 0 |
webStopOnStart |
Stop the web-server when minecraft starts | false |
webServeDynmap |
true or an absolute path to enable it, by default it will serve './plugins/dynmap/web/'. You can specify an absolute path to serve instead or an url to redirect to. How use with dynamp | false |
webSubPath |
Set the path to the Web-GUI if serving from behind a reverse proxy | "" |
webAllowRestart |
Add a button in the web-ui to restart the minecraft server proxy | false |
startMinecraft |
Start the Minecraft Server (false to disable) | true |
minecraftCommand |
The command used to start the server | "java -jar paper.jar nogui" |
minecraftAutostart |
Automatically start the real server instead of the sleeping one | false |
restartDelay |
Customise the delay between when the minecraft server stops and the sleeping server restarts ( to ensure conection are closed ) ( in milliseconds ) | 5000 |
preventStop |
Prevent the user to stop the server (trought web-server or cli). | false |
minecraftWorkingDirectory |
Set a custom Working Directory for the server EDIT ONLY IF YOU KNOW WHAT YOU'RE DOING (should be the path to the server's directory, absolute path is best) | "" |
version |
Force compatibility with a specific Minecraft. If set to false, it should handle any compatible version | "" |
favIconPath |
Path to a PNG file to use as the server icon. If this is set to server-icon.png then it will use the same icon as the server. |
"" |
favIcon |
Use a custom server-icon 64x64 png converted using https://www.base64-image.de/ (needs to be encoded in base64) | "" |
discordWebhookUrl |
Setup a Discord WebHook to your channel | "REPLACE_ME" |
blackListedAddress |
Prevent connections from those addresses to wake up the server | ["127.0.0.1"] |
whiteListedNames |
Only allow people with their name on the white list to wake the server up | ["vincss"] |
useWhitelistFile |
Use Minecraft whitelist.json instead of the whiteListedNames property. Checks both username and UUID |
false |
useBlacklistFiles |
Use Minecraft banned-ips.json and banned-players.json to prevent players from waking up the server. Can be used together with blackListedAddress property |
false |
hideIpInLogs |
Hide the ip from the remote player in the logs | false |
hideOnConnectionLogs |
Hide 'A Prince has taken a quick peek' the logs | false |
useLegacyLogin |
use legacy "login" method from minecraft-protocol | false |
Note: if you need to shutdown the program, simply input a
ctrl + c
, the program will shut down normally afterwards
While SleepingServerStarter is made to run on a single server, it can be integrated to a Bungeecord network. But please note that you'll need to install and configure SleepingServerStarter on every servers you want to be affected by the program.
Installing SleepingServerStarter only on your proxy server will NOT work
For each server you're installing SleepingServerStarter on :
serverPort
should be the port of the server you're installing the program on, not the
proxy's portserverOnlineMode
is set to false
to avoid any problems with Bungee when switching
between serversWe know this can be a little bit time consuming, but this solution is working great
When trying to join a sleeping server, you get this kind of message by Bungee
Basically, it keeps kicking the player with loginMessage
as reason, telling the player the server
is being started
Contributions, issues and feature requests are welcome!
Feel free to
check issues page
Give a βοΈ if you like the project!