This docker image allows you to run a server for FiveM, a modded GTA multiplayer program.
This image also includes txAdmin, an in-browser server management software.
Upon first run, the configuration is generated in the host mount for the /config
directory, and for the /txData
directory (that contains the txAdmin configuration).
The container should be stopped so fivem can be configured to the user requirements in the server.cfg
.
A freely obtained licence key is required to use this server, which should be declared as $LICENCE_KEY
. A tutorial on how to obtain a licence key can be found here
Use the docker-compose script provided or use the line below:
docker run -d \
--name FiveM \
--restart on-failure \
-p 30120:30120 \
-p 30120:30120/udp \
-p 40120:40120 \
-e WEB_PORT=40120 \
-e FIVEM_PORT=30120 \
-e HOST_UID=1000 \
-e HOST_GID=1000 \
-e LICENCE_KEY=<your-license-key> \
-e SERVER_PROFILE=default \
-v /volumes/fivem:/config \
-v /volumes/txAdmin:/txData
-tid \
andruida/fivem
When the container is running you can access txAdmin on the specified port and login with the username administrator
and the password adminadmin
. After login, immediately change login the password.
It is important that you use interactive
and pseudo-tty
options otherwise the container will crash on startup
See issue #3
LICENSE_KEY
- This is a required variable for the licence key needed to start the server.RCON_PASSWORD
- A password to use for the RCON functionality of the fxserver. If not specified, a random 16 character password is assigned. This is only used upon creation of the default configsWEB_PORT
- Sets up txAdmin to run on this port. If not specified, will use40120
by default.FIVEM_PORT
- If the server.cfg file needs to be generated, the server will use this port. If not specified, will use30120
by default.HOST_GID
- The files that are generated by the container will be written with this group ID. You must use numeric IDs. If not specified, will use0
(root).HOST_UID
- The files that are generated by the container will be written with this user ID. You must use numeric IDs. If not specified, will use0
(root).SERVER_PROFILE
- profile name used by txAdmin. If not specified, will usedev_server
.
- This image is based on the spritsail/fivem image. Thanks to Spritsail !
- Thanks to tabarra as the creator and maintainer of the txAdmin repository!