├── .gitignore ├── .editorconfig ├── docker-compose.yml ├── server.cfg ├── Makefile ├── install.sh ├── Dockerfile ├── LICENSE └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | /qemu-arm-static 2 | /pak0.pk3 3 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig is awesome: http://EditorConfig.org 2 | 3 | [*] 4 | end_of_line = lf 5 | insert_final_newline = true 6 | indent_style = space 7 | indent_size = 2 8 | 9 | [Makefile] 10 | indent_style = tab 11 | indent_size = 4 12 | -------------------------------------------------------------------------------- /docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '2' 2 | 3 | services: 4 | server: 5 | image: wouterds/rpi-quake3-server 6 | restart: unless-stopped 7 | volumes: 8 | - ./pak0.pk3:/data/pak0.pk3 9 | - ./server.cfg:/data/server.cfg 10 | ports: 11 | - '27960:27960/udp' 12 | mem_limit: 64mb 13 | -------------------------------------------------------------------------------- /server.cfg: -------------------------------------------------------------------------------- 1 | seta sv_hostname "wouterds/rpi-quake3-server" 2 | seta sv_maxclients 12 3 | seta sv_pure 1 4 | //seta logfile 3 5 | //seta rconpassword "secret" 6 | 7 | seta timelimit 15 8 | seta fraglimit 20 9 | //seta capturelimit 8 // CTF limit 10 | 11 | seta g_gametype 0 // 0: FFA, 1: Tourney, 2: FFA, 3: TD, 4: CTF 12 | seta g_friendlyFire 0 13 | seta g_teamAutoJoin 0 14 | seta g_teamForceBalance 1 15 | seta g_inactivity 120 16 | 17 | // Map cycle 18 | set map1 "map Q3DM1; set nextmap vstr map2" 19 | set map2 "map Q3DM6; set nextmap vstr map3" 20 | set map3 "map Q3DM17; set nextmap vstr map1" 21 | vstr map1 22 | 23 | // Bots 24 | seta bot_enable 1 25 | seta bot_nochat 0 26 | seta g_spskill 2 27 | seta bot_minplayers 4 28 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | all: tag 2 | 3 | PWD = $(shell pwd) 4 | 5 | VERSION = 1.0.0 6 | PROJECT_NAME = rpi-quake3-server 7 | 8 | DOCKERFILE = ./Dockerfile 9 | TAG = wouterds/$(PROJECT_NAME) 10 | 11 | clean: 12 | -rm -f ./qemu-arm-static 13 | 14 | qemu-arm-static: 15 | docker run --rm --privileged multiarch/qemu-user-static:register --reset 16 | curl -OL https://github.com/multiarch/qemu-user-static/releases/download/v4.1.0-1/qemu-arm-static 17 | chmod +x qemu-arm-static 18 | 19 | build: qemu-arm-static ./Dockerfile 20 | docker build -f ./Dockerfile -t $(TAG) . 21 | 22 | tag: build 23 | docker tag $(TAG) $(TAG):$(VERSION) 24 | 25 | push-version: tag 26 | docker push $(TAG):$(VERSION) 27 | 28 | push-latest: tag 29 | docker push $(TAG):latest 30 | 31 | push: push-version push-latest 32 | -------------------------------------------------------------------------------- /install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | 4 | # This script is meant for quick & easy install via: 5 | # $ curl -sSL https://github.com/wouterds/rpi-quake3-server/raw/master/install.sh | sh 6 | 7 | echo 'Creating ./quake3 directory...' 8 | mkdir quake3 9 | cd quake3 10 | 11 | echo 'Downloading assets...' 12 | curl -LO https://github.com/wouterds/rpi-quake3-server/raw/master/docker-compose.yml 13 | curl -LO https://github.com/wouterds/rpi-quake3-server/raw/master/server.cfg 14 | curl -LO https://github.com/wouterds/rpi-quake3-server/releases/download/1.0.0/pak0.pk3 15 | 16 | echo '' 17 | echo 'Ready to go!' 18 | echo '' 19 | echo 'You can customize your server settings by editing: ./quake3/server.cfg' 20 | echo 'When ready, start the server by running "cd ./quake3 && docker-compose up -d"' 21 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM arm32v6/alpine 2 | 3 | COPY ./qemu-arm-static /usr/bin/qemu-arm-static 4 | RUN apk --no-cache add curl g++ gcc git make 5 | RUN mkdir -p /tmp/build 6 | RUN curl https://raw.githubusercontent.com/ioquake/ioq3/master/misc/linux/server_compile.sh -o /tmp/build/compile.sh 7 | RUN curl https://ioquake3.org/data/quake3-latest-pk3s.zip --referer https://ioquake3.org/extras/patch-data/ -o /tmp/build/quake3-latest-pk3s.zip 8 | RUN echo 'y' | sh /tmp/build/compile.sh 9 | RUN unzip /tmp/build/quake3-latest-pk3s.zip -d /tmp/build/ 10 | RUN cp -r /tmp/build/quake3-latest-pk3s/* ~/ioquake3 11 | 12 | FROM arm32v6/alpine 13 | LABEL maintainer="wouterds " 14 | 15 | COPY ./qemu-arm-static /usr/bin/qemu-arm-static 16 | COPY --from=0 /root/ioquake3 /home/ioq3srv/ioquake3 17 | RUN ln -sf /data/pak0.pk3 /home/ioq3srv/ioquake3/baseq3/pak0.pk3 && \ 18 | ln -sf /data/server.cfg /home/ioq3srv/ioquake3/baseq3/server.cfg && \ 19 | adduser ioq3srv -D && \ 20 | rm /usr/bin/qemu-arm-static 21 | 22 | USER ioq3srv 23 | EXPOSE 27960 24 | 25 | ENTRYPOINT ["/home/ioq3srv/ioquake3/ioq3ded.arm", "+exec", "server.cfg"] 26 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) [year] [fullname] 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Quake III Arena Docker Alpine image with ARM support 2 | 3 | This Docker image provides a simple Quake 3 dedicated server that runs on Raspberry Pi. 4 | 5 | [![Quake 3 on Raspberry with Docker](https://wouterdeschuyter.be/static/media/2fc444b5-e80e-49bb-85ef-71c3023e0e88.jpg)](https://wouterdeschuyter.be/blog/running-a-dedicated-quake-3-arena-server-on-raspberry-pi-with-docker) 6 | 7 | ## Installing 8 | 9 | ### With script 10 | 11 | ```bash 12 | curl -sSL https://github.com/wouterds/rpi-quake3-server/raw/master/install.sh | sh 13 | ``` 14 | 15 | ### Manually 16 | 17 | 1. Create a directory where you'll run the project, e.g. `quake3` 18 | 19 | 2. Copy [`docker-compose.yml`](/docker-compose.yml) into the directory 20 | 21 | 3. Copy [`server.cfg`](/server.cfg) into the directory 22 | 23 | 4. Copy the [pak0.pk3](https://github.com/wouterds/rpi-quake3-server/releases/download/1.0.0/pak0.pk3) file into the directory 24 | 25 | 26 | ### Configuring 27 | 28 | Change server settings by editing `./server.cfg` 29 | 30 | ## Running 31 | 32 | ```bash 33 | docker-compose up -d 34 | ``` 35 | 36 | ## Client 37 | 38 | Find a client for your platform here: https://ioquake3.org/get-it 39 | --------------------------------------------------------------------------------