Hosting a fivem server on my truenas

hello internet
to make it short and sweet. ive been trying to set up a fivem server on my truenas via docker apps. im using this one
https://hub.docker.com/r/spritsail/fivem

i can set one up and then configure it with txdmin and then join it. no problems. the problem is that when i shut down the app and then start the server (app) again it doesnt know where the server is because it prompts the setup process again.
all video tutorials on youtube show how to set one up on my own machine on the desktop. do people with 200 player servers host stuff on their own windows machine and then play from that too? or do they buy a regular pc, install windows on it and go from there?
there are docker images out there and it there must be a couple people who host their service like that. i mean thats what truenas or unraid is for.

im just confused and need help understanding this mess :frowning:

Most “big” servers are hosted on proper VPSes under Windows Server licenses, in my experience, docker is finicky exactly for this reason. See if there’s some kind of “persistent path” thing in your docker, and make sure the entire server is installed in one so it can be found by the other apps that need it.

awesome, thanks for the reply. thats something im having an issue with too in fact. it doesnt seem to create the folder i need visible. i need “txData” and “config” i think where the “server.cfg” file is. im not getting that at all. ive posted on reddit in the truenas thing and i just cant get it to work.
another big questionmark for me is, if i use tx admin. i need it to tell it where those files are, right. if i host it from my desktop it knows its on my desktop, of course. but what path would it be for me if i have it on another machine? how do you do it? do i even need txadmin at all? i cant imagine everyone is hosting servers from their desktop and leaving it on 24/7.
what are VPS’s?

in theory i could run a virtual machine on truenas and run it that way but wouldnt that use a lot more resources than a docker app?

That’s up to however your network is set up, however everything to do with the server (including the symbols, executable, txAdmin etc) needs to be on the same machine and ideally on the same drive. The core of the issue lies in wherever the files are saved, if you figure out how to make those paths persistent then you should be good.

1 Like

My dev server is on my homelab machine which runs Docker and the same container you are using. @_4iY is correct, you need to have a writable volume mapped to be able to have persistence. Otherwise, you will not be able to do much of anything. Not even install resources in the future.

Read up on creating a proper docker-compose.yaml file, with particular attention to volumes. That should fix you right up.

1 Like

If you plan on running additional services (i.e., a web server, database, caching server, etc.), you may find the VM more viable. I would suggest sitting down and considering what you’re trying to achieve - if you want to host a little mess-around server for you and a few friends: docker. If you’re serious about creating a larger server, maybe VMs are your answer.

Also, from my limited understanding of TrueNAS, you actually have more control over the resource allocation of VMs vs. Docker Apps, since Docker Apps only allow you to specify CPU & Memory Limits, whereas in VMs you can select the number of CPUs (if you have multiple), Core Count, Thread Count, etc.

Food for thought.

i wannt to be able to create a server for 10 people max. mainly for friends.

are you using truenas? i think truenas doesnt use yaml files(?) i can create / pull custom docker images via this set up page in truenas (like env. variables, ports, storage).
if you use truenas, can you show me a screenshot how you set up the storage part?

@ChristopherM @DaveGaffer @_4iY this is my reddit post. i have a couple screenshots there because i have issues making it persist, the data. maybe one of you can help me figure this out. this cant be that hard. i must be doing something wrong.
https://www.reddit.com/r/truenas/comments/1drmbks/comment/lawlu5y/?context=3

I am not, no. My server is an old workstation PC simply running Linux. I run Docker and manage my containers with Portainer. I do automated upgrades of my containers with Watchtower.

I will not be able to provide a screenshot nor a brief walk-through. What I have running took almost a year to get working smoothly. It’s not something I can convey in a short time.

It will take some time for you to learn what you need. Docker Compose will allow you to run your FX server and your mySQL and other accompanying services within the same application in Docker.

My recommendation stands. Read more about:

The recommendations for a VPS (virtual private server) are valid as well. For a production environment where one needs DDOS protection, backups, and other failsafes, this is the way to go. For up to ten players, if your hardware can stand it, you should be able to use a self-hosted server with Docker with no problem.

1 Like

thanks for the infos, appreciate it

1 Like