Skip to content
This repository has been archived by the owner on Jun 30, 2022. It is now read-only.
/ spn-docker Public archive

Schlangenprogrammiernacht - Ein Programmierspiel für die GPN - Docker-Wrapper

Notifications You must be signed in to change notification settings

Bytewerk/spn-docker

Repository files navigation

SPN Docker Environment

IMPORTANT: This is a repository related to the GPN18 version of SPN. It is no longer maintained. See https://github.com/schlangenprogrammiernacht/spn-meta for the GPN19 version!

This repository contains DockerFiles and scripts used to set up a SPN server for quick testing.

The Docker environment should currently not be used to set up a “production” server as database migrations do not work properly.

Preparing the repository

This repository contains the other SPN repositories (gameserver, relayserver and website) as git submodules. These have to be initialized:

git submodule update --init --recursive

Afterwards you can go to each <program>/code directory and check out the revision you’d like to test.

Preparing Docker images

Some program share a common, static base layer, which must be built first:

./0_build_baselayer.sh

Afterwards, images for the different programs can be built:

./1_build_images.sh

Running the programs

A wrapper script exists for convenience:

./2_run.sh

This script starts the database container in the background, waits 5 seconds and then starts the other containers in the foreground.

If you are starting the containers from a clean state, 5 seconds may not be enough to get the database up before the other containers. It is recommended to run the containers individually like this:

docker-compose up -d database
sleep 10
docker-compose up -d website    # this initializes the database
sleep 10
docker-compose up               # runs the rest and shows log messages

Visiting the game

The game can be reached at localhost:80. Don't use Port 8000, because static files (for example css, js) won't be served.

About

Schlangenprogrammiernacht - Ein Programmierspiel für die GPN - Docker-Wrapper

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •