Bugfixes (thanks civ)

This commit is contained in:
Neale Pickett 2015-04-13 13:14:40 -06:00
parent 132cdaa769
commit 0a37c53852
2 changed files with 28 additions and 7 deletions

22
README
View File

@ -26,9 +26,9 @@ so you can run multiple contests at once if you want.
If you were to want to run it out of `/opt/koth`, If you were to want to run it out of `/opt/koth`,
do the following: do the following:
$ mkdir -p /opt/hack/mycontest $ mkdir -p /opt/koth/mycontest
$ ./install /opt/hack/mycontest $ ./install /opt/koth/mycontest
$ cp kothd /opt/hack $ cp kothd /opt/koth
Yay, you've got it set up. Yay, you've got it set up.
@ -37,18 +37,26 @@ Installing Puzzle Categories
------------------------------------ ------------------------------------
Puzzle categories are distributed in a different way than the server. Puzzle categories are distributed in a different way than the server.
If you have one, After setting up (see above), just run
just run
$ /opt/koth/hack/bin/install-category /path/to/my/category $ /opt/koth/mycontest/bin/install-category /path/to/my/category
Running It Running It
------------- -------------
Get your web server to serve up files from Get your web server to serve up files from
`/opt/koth/hack/www`. `/opt/koth/mycontest/www`.
Then run `/opt/koth/kothd`. Then run `/opt/koth/kothd`.
Permissions
----------------
It's up to you not to be a bonehead about permissions. It's up to you not to be a bonehead about permissions.
Install sets it so the web user on your system can write to the files it needs to,
but if you're using Apache,
it plays games with user IDs when running CGI.
You're going to have to figure out how to configure your preferred web server.

13
kothd Normal file
View File

@ -0,0 +1,13 @@
#! /bin/sh
cd ${1:-$(dirname $0)}
KOTH_BASE=$(cwd)
echo "Running koth instances in $KOTH_BASE"
while true; do
for i in $KOTH_BASE/*/assigned.txt; do
dir=${i%/*}
$dir/bin/once
done
done