Git Product home page Git Product logo

beammp-docker's Introduction

beammp-docker

CI Docker Hub pulls Docker Hub size trivy

This project provides a small, alpine based, docker container for the beammp game server and shows its usage in a docker-compose environment.

Motivation

Because there were no well-documented, alpine based beammp docker images out there, I did one by myself. Building the beammp server is needed, because the prebuilt linux binary uses glibc as C standard library implementation (instead of musl).

Usage

The sections below provides use cases for docker and docker-compose.

docker

Quick start:

docker run --name beammp-server \
           -p 30814:30814/tcp -p 30814:30814/udp \
           -e NAME='My first awesome Server' \
           -e AUTH_KEY='<insert auth-key>' \
           rouhim/beammp-server

docker-compose

Check docker-compose.yml if interested. The configuration should be done within the .env file.

To get started copy .env.example to .env.

cp .env.example .env

Adjust the values in the .env to your needs and run:

docker-compose pull && docker-compose up -d

Environment parameter

Variable name description default value
AUTH_KEY **
Mandatory!** The authentication key used by the server. It is used to identify your server and is not optional. empty
DEBUG Set to true to enable debug output in the console false
PRIVATE Set to true if you don't want to show up in the Server Browser true
CARS How many vehicles a player is allowed to have at the same time 1
MAX_PLAYER How many players your server can hold at a time 10
MAP What the server map is /levels/gridmap_v2/info.json
NAME What your server is called. This shows up in the Server Browser BeamMP New Server
DESC What shows under the name when you click on the server BeamMP Default Description
PORT This value must be identical to the containers exposed port. 30814

A new AUTH_KEY can be claimed on this site, you will need a Discord account for this. Note that the IP entered there does not matter, despite what the site claims. For more information refer to this wiki page.

Game mods

In the first place you should consider reading the official mods guide.

The folder mods is created automatically during the first startup, but can also be created manually beforehand.

Vehicle mods:

Just copy the downloaded zip file into the mods folder.

Custom maps:

Copy the downloaded zip file into the mods folder.

Now we have to find out the custom map path name (e.g.: /levels/car_jump_arena/info.json), to set it later in the as map to load.

To do so:

  1. Execute the shell command below, or open the zip file manually.
  2. Copy the absolute path to the info.json location (/levels/{map-name}/info.json).
  3. Set in .env file: MAP=/levels/{map-name}/info.json. Example: MAP=/levels/car_jump_arena/info.json

A simple way to print the full map path including info.json (unzip, grep and awk is required):

unzip -l PATH/TO/MAP.zip \
  | grep 'levels/.*/info.json' \
  | awk '{split($0,a," "); print "/"a[4]}'

Used materials

beammp-docker's People

Contributors

lionkor avatar rouhim avatar

Watchers

 avatar  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.