Code Monkey home page Code Monkey logo

dst-server's Introduction

dst-server

Simple docker-compose setup for a Don't Starve Together server running on LinuxGSM. App can be built to be portable for cloud container services.

Build the app with docker-compose up --build.

You can change the ENVs in the docker-compose. ENVs control the basic server config. I only picked the configs I cared about. Feel free to fork and change them up.

SERVER_PASSWORD       # Sets the server password (string)
SERVER_NAME           # Sets the server name (string)
SERVER_DESCRIPTION    # Sets the server description (string)
SERVER_INTENTION      # Sets the server intention (cooperative|competitive|social|madness)
CLUSTER_NAME          # Sets the cluster name. This controls what directory your cluster runs in. (string)
CLUSTER_TOKEN         # Required token from Klei to run a server. SERVER WILL NOT START WITHOUT THIS! (string)
GAME_MODE             # Sets the game mode (survival|endless|wilderness)
MAX_PLAYERS           # Sets the max players (int, 1..64)
ENABLE_PVP            # Enables PVP (true|false)
ENABLE_CONSOLE        # Enables the Lua console (true|false)
MAX_SNAPSHOTS         # Number of backup snapshots to keep of your world (int)
HEALTH_CHECK_PORT     # Sets the health check port (int)
ENABLE_CLEAN_SHUTDOWN # Enables the clean shutdown script. This script runs the vhserver stop command on SIG traps. (0, 1)
UPDATE_ON_RUN         # Updates LinuxGSM and the Valheim server on run (0, 1)

If you want to make sure the world saves before the container exits, enable ENABLE_CLEAN_SHUTDOWN in the ENV. Don't Starve Together saves to the world files when players leave and in time intervals. Killing the container suddenly could lead to corruption or world progress loss, so I recommend enabling this option.

If you want to the server to update itself (like on a nightly reboot cron) enable UPDATE_ON_RUN in the ENV. This will run both the LinuxGSM and Don't Starve Together server update commands before the server boots up. Keep in mind the server will start faster with this disabled. If disabled, remember to update the server manually or re-build the container periodically to install new versions.

Mods

Don't Starve Together supports mods. You need to fill out the Lua mod files yourself.

scripts/dedicated_server_mods_setup.lua
scripts/modsettings.lua

After you configure those files, you can enable mods by setting:

ENABLE_MODS # Enables mods (0, 1)

This ENV is optional. Not setting ENABLE_MODS will cause the server to assume mods are disabled.

Useful file locations

# Holds the Don't Starve Together world files
# This directory is setup as a volume to remain persistent
/home/linuxgsm/.klei/DoNotStarveTogether/

# Holds the GSM and game logs
# This directory is setup as a volume to remain persistent
/home/linuxgsm/gsm/log/

# Holds the Don't Starve Together mod files
/home/linuxgsm/gsm/serverfiles/mods

Hot Tips

Don't forget to your Cluster Token from Klei or your game won't start!

  • Go to the Klei website.
  • Get your game server authentication token.
  • Enter a friendly name for your server and copy the access token and set CLUSTER_TOKEN.

dst-server's People

Contributors

jetbo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.