diff --git a/README.md b/README.md index cf28b73..f98ef44 100644 --- a/README.md +++ b/README.md @@ -2,13 +2,19 @@ This project aims to autostart a Stardew Valley Multiplayer Server as easy as possible. -# Setup +## Setup ``` git clone https://github.com/printfuck/stardew-multiplayer-docker docker-compose up ``` -# How it works +Intially you have to create or load a game once after first startup. After that the Autoload Mod jump starts into the previously loaded savegame everytime you rerun the container. You can also edit the config file of the Autoload Mod to archieve similar behaviour. + +## How it works The game, the modloader (SMAPI), and the "Always On" Mod is pulled from my servers to minimize version conflicts. Afterwards everything will be unpacked into the right places. In the end of the init script the game will be started inside Xvfb. + +## Why Docker + +This should be simple and easily deployable, so there are only a few options. diff --git a/asound.conf b/asound.conf new file mode 100644 index 0000000..4153000 --- /dev/null +++ b/asound.conf @@ -0,0 +1,4 @@ +pcm.!default { + type plug + slave.pcm "null" +} diff --git a/docker-compose.yml b/docker-compose.yml index b6b322f..b3b69e7 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,21 +1,23 @@ -version: '3.7' +version: '2.2' services: valley: build: . ports: - 5902:5900 - - 24642:24642 + - 24642:24642/udp volumes: - /data/valley:/data - ./init.sh:/init.sh - # - ./asound.conf:/etc/asound.conf + - ./asound.conf:/etc/asound.conf - ./config:/root/.config/i3/config - /data/valley_saves:/root/.config/StardewValley/Saves/ devices: - - /dev/dsp:/dev/dsp + #- /dev/dsp:/dev/dsp - /dev/snd:/dev/snd entrypoint: - /bin/sh - /init.sh + cpus: 0.5 + cpuset: '2' diff --git a/playbook.yml b/playbook.yml new file mode 100644 index 0000000..6101a7a --- /dev/null +++ b/playbook.yml @@ -0,0 +1,10 @@ +--- + +- name: Example + hosts: "all" + become: true + + roles: + - role: "nickjj.docker" + tags: ["docker"] + - role "stardew"