Skip to content
This repository has been archived by the owner on Jan 15, 2022. It is now read-only.
Mario Zechner edited this page Jul 15, 2015 · 6 revisions

Deploying the site

The site is composed of two things: a REST-like server written in Dropwizard and a simple web frontend. All of that is deployed to libgdx.badlogicgames.com, in /opt/libgdx-site to which this repo is cloned. Once cloned, we run this:

git pull
cd src/main/webapp
./build.sh
cd ../../..
mvn clean package
cp -r src/main/webapp/* /usr/share/nginx/html/
java -jar target/libgdx-site-jar-with-dependencies.jar

build.sh compiles the web frontend sources in src/main/webapp/src. These are then copied to /usr/share/nginx/html from which the frontend of the website is served. Next we compiled the backend via maven and start it up as a fat jar. It's responsible for the gallery of the website. Gallery submissions are stored to /opt/gamedb, one file per entry (yes it's a flat file storage cause i'm lazy :D)

The script above is actually run in a screen session. When logging into libgdx.badlogicgames.com, simply execute screen -r. At the bottom you see a couple of tabs, 0 libgdx-site is where the backend server is running. See the screen reference on how to use screen.

Clone this wiki locally