As to DoNotStarveTogether Dedicated Server
, I finally realized that steamcmd
is only a game server files downloader. That is to say, what I need is just a game server runtime.
Modifying server settings by hand reduces the difficulty of runtime building and improves its compatibility.
Optimized for mutliple shards(>=3). Every shard run in a single container.
- Serve mutiple shards. (1 or more)
- Simple but powerful. (dedicated downloader and runtime)
- Clone the project and change your working directory
git clone https://gitee.com/maoxuner/yadst.git cd yadst
- Generate a cluster token and download base cluster config from next link
https://accounts.klei.com/account/game/servers?game=DontStarveTogether - Extract downloaded files to
root-path-of-yadst/server/data/DoNotStarveTogether/MyDediServer
root-path-of-yadst/server ├── data │ └── DoNotStarveTogether │ └── MyDediServer │ ├── Caves │ │ ├── server.ini │ │ └── worldgenoverride.lua │ ├── Master │ │ ├── server.ini │ │ └── worldgenoverride.lua │ ├── cluster.ini │ └── cluster_token.txt └── game
- Edit world and mods settings [manually]
- Build runtime image (or use yadst)
docker build -t yadst-runtime .
- Download game and mods files
# download game docker run --rm -v $PWD/server/game:/opt/dst/game steamcmd/steamcmd +force_install_dir /opt/dst/game +login anonymous +app_update 343050 validate +quit # download mods docker run --rm -v $PWD/server/game:/opt/dst/game -v $PWD/server/data:/opt/dst/data -w /opt/dst/game/bin64 yadst-runtime ./dontstarve_dedicated_server_nullrenderer_x64 -ugc_directory /opt/dst/game/ugc_mods -persistent_storage_root /opt/dst/data -conf_dir DoNotStarveTogether -cluster MyDediServer -shard Master -only_update_server_mods
- After game files downloaded, start game servers
docker compose up -d
These projects have done a great job. Some ideas or scripts come from them.