A simple docker and docker-compose for running a PvPGN-PRO server in no time
Yet another pvpgn-docker project. Aims to be:
- ⌛ time-proof - builds binaries directly from source
- 🔐 secure - uses non-privileged user and group to run the server
- 🗜 small - based on Alpine linux
- ⚖ lightweight - final image doesn't contain source or build tools
Most users should be fine running the official image. Use this image if you prefer Alpine's smaller footprint or if you plan to develop on PvPGN, as the dependencies are installed only once here.
Pull the image from Docker Hub:
docker pull wwmoraes/pvpgn-server
Then/or just run:
docker run -it wwmoraes/pvpgn-server
PvPGN-PRO is built and installed on the root filesystem. A sample configuration
can be found at /etc/pvpgn
. Data (logs, storage, scripts, etc) can be found
at /var/pvpgn
. These are the default locations bnetd
will use, unless you
configure it to use distinct paths.
The configuration and data paths should be bound to volumes for persistence, and the ports should be published so you can access the server outside of the container:
docker run -it -p 6112:6112 -p 4000:4000 \
-v <your-config-volume-or-path>:/etc/pvpgn \
-v <your-data-volume-or-path>:/var/pvpgn \
wwmoraes/pvpgn-server
IMPORTANT: Make sure the volumes/bind mount sources are readable and writable by the server user and group. The image default is 1001.
The build is done with Lua script support enabled, and MySQL support for the account backend.
You can create persistent local volumes for the config and data without starting the server with:
docker run --rm --entrypoint=true \
-v <your-config-volume-name>:/etc/pvpgn \
-v <your-data-volume-name>:/var/pvpgn \
wwmoraes/pvpgn-server
Both volumes must not exist prior to this call for Docker to create and populate them with the image contents.
You can also copy the files to your host system using a temporary bind mount, for instance:
mkdir {var,etc}
docker run --rm --entrypoint=cp --user "$(id -u):$(id -g)" \
-v $PWD/var:/mnt/var \
wwmoraes/pvpgn-server \
-r /var/pvpgn /mnt/var
docker run --rm --entrypoint=cp --user "$(id -u):$(id -g)" \
-v $PWD/etc:/mnt/etc \
wwmoraes/pvpgn-server \
-r /etc/pvpgn /mnt/etc
Please refer to the upstream documentation on how to configure your server.