Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ Add Valheim server #697

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

anarion80
Copy link
Contributor

What this PR does / why we need it:

Adds valheim-docker server.

Which issue (if any) this PR fixes:

Fixes #696

Any other useful info:

@anarion80
Copy link
Contributor Author

I don't play the game and have no means to check this further, but the server itself seems to work:

03/05/2024 12:54:45: Game server connected
[Valheim][steam]: ###########################################################################
[Valheim][steam]: Valheim Server - Tue Mar  5 13:00:01 CET 2024 Backup Process
[Valheim][steam]: Starting auto backup process...
[Valheim][steam]: Removing old backups...
[Valheim][steam]: Creating backup...
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/adminlist.txt to backup file, with path /adminlist.txt
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/bannedlist.txt to backup file, with path /bannedlist.txt
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/permittedlist.txt to backup file, with path /permittedlist.txt
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/prefs to backup file, with path /prefs
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/worlds_local to backup file, with path /worlds_local
[ODIN][INFO]  - Adding /home/steam/.config/unity3d/IronGate/Valheim/worlds_local/Dedicated.fwl to backup file, with path /worlds_local/Dedicated.fwl
[Valheim][steam]: Backup process complete! Created 20240305-130001-backup.tar.gz
[Valheim][steam]: ###########################################################################
03/05/2024 13:04:48:  Connections 0 ZDOS:81  sent:0 recv:0

Copy link
Owner

@davestephens davestephens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Have added a few comments for your review...

roles/valheim/defaults/main.yml Outdated Show resolved Hide resolved
roles/valheim/molecule/default/verify_stopped.yml Outdated Show resolved Hide resolved
roles/valheim/tasks/main.yml Outdated Show resolved Hide resolved
roles/valheim/tasks/main.yml Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
Copy link
Owner

@davestephens davestephens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nearly there, I think

roles/valheim/defaults/main.yml Outdated Show resolved Hide resolved
@elliotpryde
Copy link

Just noticed this MR - will test and get back to you.

What do the 'available externally' traefik tags do? To connect to this server externally, the game requires that the server is reachable on those 3 specified ports (none of which are 443), so these ports needed to be forwarded from your router additionally. Once that's done you can reach the server using your *.myawesomedomain.com wildcard DNS entry (e.g. valheim.myawesomedomain.com - no traefik magic required

@anarion80
Copy link
Contributor Author

Indeed, there is no fronted to speak of here, so this is not really need for traefik, but then this role can't do everything for the user.

@elliotpryde
Copy link

Yes, there's no getting around the fact that the user will need to make their NAS server accessible on the specified ports from the external network. I suspect that the Minecraft server role has the same caveat. Router automation is outside the scope of the ansible-nas project, but this role will do 95% of the work for users, and the last 5% could be added to the README.

@elliotpryde
Copy link

Tested and working with the default variables when connecting to valheim.<mydomain>:2456

valheim-ansible-nas

@elliotpryde
Copy link

Yes, there's no getting around the fact that the user will need to make their NAS server accessible on the specified ports from the external network. I suspect that the Minecraft server role has the same caveat. Router automation is outside the scope of the ansible-nas project, but this role will do 95% of the work for users, and the last 5% could be added to the README.

users already had to do this for port 80/443, so 3 more ports shouldn't require a lot of explanation/effort https://ansible-nas.io/docs/getting-started/external-access/#router-configuration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add valheim-docker
3 participants