Skip to content

Latest commit

 

History

History
114 lines (80 loc) · 5.08 KB

File metadata and controls

114 lines (80 loc) · 5.08 KB

Pipeline Pipeline Docker Hub pulls Docker Hub size trivy os-arch Donate me

This repository provides a safe container image for the Sons of the Forest game server. It is designed to be used with Docker Compose, making it easy to set up and manage your game server environment.

Requirements

Installation

Once Docker and Docker Compose are installed, clone this repository to your local machine:

git clone https://github.com/RouHim/sons-of-the-forest-container-image.git
cd sons-of-the-forest-container-image

Before starting the server, create the required folder structure, and adjust the permissions:

mkdir config/ data/ 
chmod 777 config/ data/

The chmod command is recommended to avoid permission issues. The main reason is, that the user in the container, most likely differs from the user on the host.

Usage

To start the Sons of the Forest server, navigate to the cloned repository's directory and use Docker Compose:

docker compose pull
docker compose up -d

This will pull the latest image and start the server in detached mode.

When starting the server for the first time:

  • The config files and folders will be automatically created in the config/ folder.
  • The server will download the latest version of the game from Steam to the data/ folder.

You have to restart after the first start.

To restart the server after making changes to the configuration, use the following command:

docker compose restart

To check the server logs, use the following command:

docker compose logs -f

Update

To update the server, just restart the container. The server checks for updates and validates on every boot per default.

To skip update and validation of the server files on every boot, set the FAST_BOOT env variable to true.

Configuration

The server configuration does not differ from the official server configuration. Just follow an existing server configuration guide like this.

The config folder contains the configuration files for the game server:

  • The server owners list, in a file called ownerswhitelist.txt
  • The game server configuration, in a file called dedicatedserver.cfg
  • The game saves, in a folder called Saves
  • The game settings, in a file called SonsGameSettings.cfg

All files and folders in the config will be created automatically when the server is started for the first time.

SkipNetworkAccessibilityTest is always forced to true, because the test method is not working in a container environment.

The data/ folder contains the game server data. Feel free to modify files in this folder, but be aware that the game server must be restarted for changes to take effect. The folder can be deleted to reset the game server to its default state.

Resources