A web app ladder for table tennis or other sports. Forked from code written by Cenk Gazen and Pui Anusa.
- Install tomcat with, e.g.
apt-get install tomcat7 tomcat7-admin
. - Make sure
CATALINA_HOME
andCATALINA_BASE
are set, e.g.export CATALINA_HOME=/usr/share/tomcat7; export CATALINA_BASE=/var/lib/tomcat7
. - Run
./build.sh
. This compiles the code and copies it to$CATALINA_BASE/webapps/ladder
. If you want a different endpoint thanladder
, specify it as the argument tobuild.sh
, e.g../build.sh pingpong
. - Edit
$CATALINA_BASE/conf/context.xml
and make sure<Manager pathname="" />
is uncommented. This disables session objects to be serialized in restarts. Otherwise tomcat throws exceptions, because not all objects we store in the session are serializable. - Optionally edit
$CATALINA_BASE/conf/tomcat-users.xml
and add these lines:<role rolename="manager-gui"/>
<user username="admin" password="changeme" roles="manager-gui"/>
. This enables starting, stopping and reloading of web apps via the tomcat webapp manager. - Edit
$CATALINA_BASE/webapps/ladder/WEB-INF/web.xml
to set the ladder admin password. - Start tomcat with
$CATALINA_HOME/bin/startup.sh
. - Make sure SMTP is working. One way is
apt-get install mailutils
. - Make sure the timezone is set in
/etc/timezone
(for future shells) and in the env varTZ
(for the current shell).
Extra days per open challenge
is only applicable whenSimultaneous challenges allowed
is checked. This is the extra time a challengee gets for each of his/her current open challenges when s/he gets a new challenge.Page title
is part of the title and the main header of each page, and part of the subject line of each challenge email sent.- When the
Sticky
checkbox under theAnnouncement
text field is checked, the announcement will stay at the top of the news for the day in which the announcement was posted. - The
Submit
button at the bottom of the admin page opens a console, in which Java expressions can be evaluated. The namel
is bound in the console to the current instance of the classttLadder.Ladder
. E.g.l.getPlayer("Fred")
evaluates to the instance ofttPlayer.Player
for whichgetName()
is"Fred"
. A typical use of the console is to edit incorrectly entered challenge results. Note that the console is not necessary to reset a forgotten password, as the admin can log into a user account with the admin password. - The other text fields, dropdowns and buttons are fairly self-explanatory.
Added setting for the challenger's score in a forfeit.
An incorrect name or password at login no longer displays the password. Added to the stats page the number of successful defenses of the top rung.
Added option to require that new players start at the bottom.
Added option to allow multiple simultaneous challenges. Challengees get extra time if they already have open challenges. Page titles and headers are customizable.
Initial fork. Changed "My Settings" so players can edit their names.