An open API service indexing awesome lists of open source software.

https://github.com/longjunyu2/theforest-dedicatedserver-docker

The Dockerfile for The forest dedicated server
https://github.com/longjunyu2/theforest-dedicatedserver-docker

dedicated-server docker theforest

Last synced: about 2 months ago
JSON representation

The Dockerfile for The forest dedicated server

Awesome Lists containing this project

README

        

# TheForest-DedicatedServer-Docker
## Build
Build base image. There's only server files in this image.
```shell
cd base
docker build -t .
```
Then build final image. There's a startup shell script to start the server.
```shell
cd server
docker build -t .
```
The default `` is `longjunyu/theforest-base`.
If you want to use another name, don't forget to change to first line of `server/Dockerfile` to the one you set. `FROM `

## Run
Before creating the container, you need create a file for config and a folder for saves.
Here is a tutorial about how to creating the config file. [Dedicated Server Tutorial](https://steamcommunity.com/sharedfiles/filedetails/?id=907906289&searchtext=delicated+server)
docker cli
```shell
docker run -d \
--name= \
--net=host \
-v :/data/config/config.cfg \
-v :/data/config/saves \

```
There's some issues with bridge network mode. You will meet ```DS configurations tests: failed``` and the server WON'T startup
```shell
docker run -d \
--name= \
--net=bridge \
-p 8766:8766/udp \
-p 27015:27015/udp \
-p 27016:27016/udp \
-v :/data/config/config.cfg \
-v :/data/config/saves \

```

## Other Parameters
There are also some additional parameters that can be set to the container.
| Parameter | Function |
| ---- | ---- |
| ```-e USER_ID=1000``` | for UserID - see below for explanation |
| ```-e GROUP_ID=1000``` | for GroupID - see below for explanation |
| ```-e TZ=Asia/Shanghai``` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |

## User / Group Identifiers
When using volumes (-v flags), permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user PUID and group PGID.
Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish.
In this instance USER_ID=1000 and GROUP_ID=1000, to find yours use id your_user as below:
```id ```
Example output:
```uid=1000(your_user) gid=1000(your_user) groups=1000(your_user)```

## Pull From DockerHub
```docker pull longjunyu/theforest-server```