Giter VIP home page Giter VIP logo

pi4valheim's Introduction

pi4valheim

Experimental Docker file to run a Valheim server in a Raspberry Pi4.

The valheim.Dockerfile is based on the stardart repositories of box86 and box64.

Compiled image:

You can find in the docker hub the image to run directly: https://hub.docker.com/repository/docker/tranko/pi4valheim

Requeriments:

Raspberry Pi4: I only tested on a 8GB of RAM with the next requirements:

  • RaspianOs 64 Bits updated.
  • Upgrade the distribution to Debian BullsEye (change the repositories to):
deb http://deb.debian.org/debian           bullseye          main contrib non-free
deb http://deb.debian.org/debian-security/ bullseye-security main contrib non-free
deb http://deb.debian.org/debian           bullseye-updates  main contrib non-free

Then run the typical upgrade of Debian:

sudo apt update & sudo apt upgrade & sudo apt dist-upgrade
  • Install Podman v3.3.1 (The version that is in the Debian repository is old (3.0.1) and it does not work correctly in my case).
  • Install Docker (Tested on version 20.10.9)

Create the image (it will take around 1-2 hours)

If you use podman:

podman build -f valheim.Dockerfile
podman image tag c44a18e4e67d valheim-base:v1

If you use docker:

docker build --no-cache --tag valheim-base -f Valheim.dockerfile .

Execute the container

First step configure the env.world file:

This values don't be changed. Only if they change in the future:

STEAMAPPID=892970
BOX64_LD_LIBRARY_PATH=./linux64:/root/steam/linux32:$BOX64_LD_LIBRARY_PATH
BOX64_LOG=1
BOX64_TRACE_FILE=/root/valheim_data/output.log
BOX64_TRACE=1

This values are the real ones for yoru server:

PUBLIC=0                        # 0 private / 1 public
PORT=2456                       # Don't change if don't know what are you doing. 
NAME=YourServerName             # Your amazing name of your server.
WORLD=YourWorldName             # Your unique name of your world.
SAVEDIR=/root/valheim_data      # Where to save your data.
PASSWORD=YourUniquePassw0rd     # You can leave blank and it will not have password
                                # NOT recommended for public servers.

Second step, run the container (example with Docker):

docker run --rm --name valheim -p 2456-2457:2456-2457/udp -v /valheim_data:/root/valheim_data:rw --env-file env.world valheim-base

Considerations:

Pi4 has a limited hardware, it this is emulating x86_64 over arm64, so don't expect so high performance. It works, I didn't have any problems playing some hours. When the game saves it freeze all connections during some seconds, take it into account!!!!! Several times it does not start correctly and fail (the emulator is not yet finished and it does not work all the times). In that cases, you need to stop the process killing the process.

This experiment has been able to be done thanks to the following open source projects:

pi4valheim's People

Contributors

thorkseng avatar stevefan1999-personal 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.