Coder Social home page Coder Social logo

thomasleveil / docker-urbanterror Goto Github PK

View Code? Open in Web Editor NEW
11.0 2.0 8.0 38 KB

Dockerfile for building a docker image able to run the UrbanTerror game server

Home Page: https://hub.docker.com/r/tomdesinto/urbanterror/

Shell 66.37% Dockerfile 33.63%
docker-image urt urbanterror game-server

docker-urbanterror's Introduction

UrbanTerror server

A docker image running the UrbanTerror game server.

Usage

  • Create a /my_server/q3ut4 directory on your docker host machine.

  • Copy your UrT server.cfg config file in /my_server/q3ut4.

  • run the docker container:

      docker run -d --net host -v /my_server/q3ut4:/q3ut4 tomdesinto/urbanterror:4.3.4
    

If you want to install additional maps

Note that for tags 4.2.x, the installation directory is /home/urt/UrbanTerror42/ while it is /home/urt/UrbanTerror43/ for tags 4.3.x.

There are 2 options

Option 1:

When the docker container is booting, it will COPY the maps into the appropriate directory so the server can read it. This is the slower option, but will work always.

  • Create a folder /my_server/maps on your docker host machine.

  • Copy the pk3 map files in it.

  • Run the docker container:

      docker run -d --net host -v /my_server/q3ut4:/q3ut4 -v /my_server/maps:/maps tomdesinto/urbanterror:4.3.3
    

Option 2:

This works on 4.2.023, I don't know about older versions. This mounts your maps folder directly into a subfolder of the q3ut4 folder. The URT documentation says this shouldn't work, but one of the recent UT versions enabled it.

First, create the folder /my_server/maps on your docker host machine. Then:

  • Copy the pk3 map files in it.
  • Run the docker container:
docker run -d --net host -v /my_server/q3ut4:/q3ut4 -v /my_server/maps:/home/urt/UrbanTerror43/q3ut4/download tomdesinto/urbanterror:4.3.4

Whats the difference between Option 1 and 2?

Options 1 uses -v /my_server/maps:/maps and a script copies from /maps directly into the /home/urt/UrbanTerror43/q3ut4 folder. Option 2 uses -v /my_server/maps:/home/urt/UrbanTerror43/q3ut4/download which mounts the maps directly into the q3ut4/download folder... no copying takes place.

Option 1 is slower, but should work in future versions of UT. Option 2 is faster, but it is not verified to work in older UT versions (older than 4.3).

If you want to run the server on a different port

The URT_PORT environment variable can be set to run the Urban Terror server on a port of your choice.

To run the server on port 27000:

docker run -d --net host -v /my_server/q3ut4:/q3ut4 -e URT_PORT=27000 tomdesinto/urbanterror:4.3.4

SSH Connection

You can connect with SSH or SFTP to the docker container with user root on port 22 and using this INSECURE private key PuTTY format and starting your container as follows:

docker run -d --net host -v /my_server/q3ut4:/q3ut4 -v /my_server/maps:/maps tomdesinto/urbanterror:4.3.4 /sbin/my_init --enable-insecure-key

DO NOT expose port 22 on the Internet or anyone with that key will be able to connect as root to your container!

Build the docker image

This image is based on tomdesinto/urbanterror-data which contains just the Urban Terror files (~2GB be patient).

git clone https://github.com/thomasleveil/docker-UrbanTerror.git
cd docker-UrbanTerror
sudo docker build -t tomdesinto/urbanterror:4.3.4 .

docker-urbanterror's People

Contributors

lickwid avatar that0n3guy avatar thomasleveil avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

docker-urbanterror's Issues

Urbanterror 4.3.4

Hello,

I am using your dockerfile for the server and it is working perfectly fine ๐Ÿ‘.
But 2 month ago the version 4.3.4 of urban terror was released. Could you update the server ?

Many thanks in advance ;-)

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.