#!/bin/sh # Exit on error set -e sed -i "s/QUAKEJS_TAB_TITLE/${QUAKEJS_TAB_TITLE:=Quake JS}/" /tmp/bootstrap/index.html.template sed -i "s/QUAKEJS_CONTENT_URL/${QUAKEJS_CONTENT_URL:=content.quakejs.com}/" /tmp/bootstrap/index.html.template sed -i "s/QUAKEJS_SERVER_URL/$QUAKEJS_SERVER_URL/" /tmp/bootstrap/index.html.template if [ -n "$QUAKEJS_USE_SSL" ]; then sed -i "s/'http:\/\/'/\'https:\/\/'/g" /srv/html/ioquake3.js sed -i "s/'ws:\/\/'/\'wss:\/\/'/g" /srv/html/ioquake3.js fi cp -f /tmp/bootstrap/index.html.template /srv/html/index.html