Don't Starve Together
gamesDon’t Starve Together is an uncompromising wilderness survival game full of science and magic.
README
Don't Starve Together
From their site
Don’t Starve is an uncompromising wilderness survival game full of science and magic.
You play as Wilson, an intrepid Gentleman Scientist who has been trapped by a demon and transported to a mysterious wilderness world. Wilson must learn to exploit his environment and its inhabitants if he ever hopes to escape and find his way back home.
Enter a strange and unexplored world full of strange creatures, dangers, and surprises. Gather resources to craft items and structures that match your survival style. Play your way as you unravel the mysteries of this strange land.
Minimum RAM warning
Minimum required memory to run the server is around 512mb for a single user..
Server Ports
Don't Starve Together only requires a single port to run. All network communications are proxied through the master. The default is 10999
| Port | default |
|---|---|
| Game | 10999 |
Mods/Plugins may require ports to be added to the server
Docker Images (1)
| Name | Image |
|---|---|
ghcr.io/ptero-eggs/games:source | ghcr.io/ptero-eggs/games:source |
Startup Command
cd bin64 && coproc caves ( ./dontstarve_dedicated_server_nullrenderer_x64 -bind_ip 0.0.0.0 -port 11000 -persistent_storage_root /home/container/DoNotStarveTogether -conf_dir config -cluster server -players {{MAX_PLAYERS}} -shard Caves ); ./dontstarve_dedicated_server_nullrenderer_x64 -bind_ip 0.0.0.0 -port {{SERVER_PORT}} -persistent_storage_root /home/container/DoNotStarveTogether -conf_dir config -cluster server -players {{MAX_PLAYERS}} -shard Master && echo 'c_shutdown()' >&"${caves[1]}" Variables (9)
Max Players
Set the maximum number of players that will be allowed to join the game. This option overrides the [GAMEPLAY] / max_players setting in cluster.ini. default is 16
- Environment:
MAX_PLAYERS- Default:
16- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|integer|between:1,31
Server Token
Required to run a public server. This needs to be generated from in game. Get your token here: https://accounts.klei.com/account/game/servers?game=DontStarveTogether
- Environment:
SERVER_TOKEN- Default:
None- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string|max:64
App ID
Steam Server App ID
- Environment:
SRCDS_APPID- Default:
343050- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string|max:20
Auto-update server
This is to enable auto-updating for servers. Default is 0. Set to 1 to update
- Environment:
AUTO_UPDATE- Default:
0- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|boolean
Game mode
Valid values are survival, endless or wilderness
- Environment:
GAME_MODE- Default:
survival- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string
Cluster Name
This is the name that will show up in server browser.
- Environment:
CLUSTER_NAME- Default:
A Pterodactyl Server- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string
Cluster Description
This will show up in the server details area on the “Browse Games” screen.
- Environment:
CLUSTER_DESC- Default:
A Pterodactyl Hosted Server- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
required|string
Master Worldgen Override
Link to the lua file used to generate the master server map. Only used during the install phase.
- Environment:
MASTER_WORLDGEN- Default:
https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/dont_starve/worldgenoverride.master.lua- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string
Master Worldgen Override
Link to the lua file used to generate the caves server map. Only used during the install phase. Default generates a cave map
- Environment:
CAVES_WORLDGEN- Default:
https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/dont_starve/worldgenoverride.caves.lua- User Viewable:
- ❌
- User Editable:
- ❌
- Rules:
nullable|string
Installation Script
ghcr.io/ptero-eggs/installers:debianbash#!/bin/bash
# steamcmd Base Installation Script
#
# Server Files: /mnt/server
# Image to install with is 'debian:buster-slim'
apt -y update
apt -y --no-install-recommends install curl lib32gcc1 ca-certificates
## just in case someone removed the defaults.
if [ "${STEAM_USER}" == "" ]; then
echo -e "steam user is not set.\n"
echo -e "Using anonymous user.\n"
STEAM_USER=anonymous
STEAM_PASS=""
STEAM_AUTH=""
else
echo -e "user set to ${STEAM_USER}"
fi
## download and install steamcmd
cd /tmp
mkdir -p /mnt/server/steamcmd
curl -sSL -o steamcmd.tar.gz https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
tar -xzvf steamcmd.tar.gz -C /mnt/server/steamcmd
cd /mnt/server/steamcmd
# SteamCMD fails otherwise for some reason, even running as root.
# This is changed at the end of the install process anyways.
chown -R root:root /mnt
export HOME=/mnt/server
## install game using steamcmd
./steamcmd.sh +login ${STEAM_USER} ${STEAM_PASS} ${STEAM_AUTH} +force_install_dir /mnt/server +app_update ${SRCDS_APPID} ${EXTRA_FLAGS} validate +quit ## other flags may be needed depending on install. looking at you cs 1.6
## set up 32 bit libraries
mkdir -p /mnt/server/.steam/sdk32
cp -v linux32/steamclient.so ../.steam/sdk32/steamclient.so
## set up 64 bit libraries
mkdir -p /mnt/server/.steam/sdk64
cp -v linux64/steamclient.so ../.steam/sdk64/steamclient.so
## DST specific
## cluster token file
echo -e "getting cluster configs"
mkdir -p /mnt/server/DoNotStarveTogether/config/server/
if [ ! -f /mnt/server/DoNotStarveTogether/config/server/cluster_token.txt ]; then
echo "${SERVER_TOKEN}" >> /mnt/server/DoNotStarveTogether/config/server/cluster_token.txt
fi
## cluster configs
if [ ! -f /mnt/server/DoNotStarveTogether/config/server/cluster.ini ]; then
curl -sSL https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/dont_starve/server.cluster.ini -o /mnt/server/DoNotStarveTogether/config/server/cluster.ini
fi
## master configs
echo -e "getting master configs"
mkdir -p /mnt/server/DoNotStarveTogether/config/server/Master/
## master ini
if [ ! -f /mnt/server/DoNotStarveTogether/config/server/Master/server.ini ]; then
curl -sSL https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/dont_starve/server.master.ini -o /mnt/server/DoNotStarveTogether/config/server/Master/server.ini
fi
## master worldgen override
if [ ! -z ${MASTER_WORLDGEN} ] && [ ! -f /mnt/server/DoNotStarveTogether/config/server/Master/worldgenoverride.lua ]; then
curl -sSL ${MASTER_WORLDGEN} -o /mnt/server/DoNotStarveTogether/config/server/Master/worldgenoverride.lua
fi
## caves configs
echo -e "getting cave configs"
mkdir -p /mnt/server/DoNotStarveTogether/config/server/Caves/
## caves ini
if [ ! -f /mnt/server/DoNotStarveTogether/config/server/Caves/server.ini ]; then
curl -sSL https://raw.githubusercontent.com/ptero-eggs/game-eggs/main/dont_starve/server.caves.ini -o /mnt/server/DoNotStarveTogether/config/server/Caves/server.ini
fi
## caves worldgen override
if [ ! -z ${CAVES_WORLDGEN} ] && [ ! -f /mnt/server/DoNotStarveTogether/config/server/Caves/worldgenoverride.lua ]; then
curl -sSL ${CAVES_WORLDGEN} -o /mnt/server/DoNotStarveTogether/config/server/Caves/worldgenoverride.lua
fi
echo -e "install complete"