Moe can be installed in two possible ways:
make and edit the top-level config file to suit
your needs, leaving
TEST_USER commented out.
In this setup, everything lives in the source tree you have started with and you don't need any special privileges for neither installation or running of the evaluator.
Beware: The evaluated programs are NOT fully separated from the evaluation environment and they could interfere with it. Use it only for playing with the package, not for any real competition.
The recommended way is to let the evaluator use two user accounts. One (let's
call the user
moe) runs the evaluator and keeps all secret
files like the test data, another one (
mo-test) runs the tested
programs. There can be multiple test users if you want to run several evaluators
in parallel. However, in practice the evaluation is so fast that this is seldom
How to set up this installation:
maketo compile all programs.
configto suit your needs, in particular set
$MO_ROOT(here we will assume that it's set to
moe:x:65000:65000:MO Evaluator:/aux/mo/eval/moe:/bin/bash mo-test1:x:65001:65000:MO Tester 1:/aux/mo/eval/mo-test1:/bin/bash mo-test2:x:65002:65000:MO Tester 2:/aux/mo/eval/mo-test2:/bin/bash
bin/mo-installas root to create the directory hierarchy under
$MO_ROOTinstall all parts of the evaluator there and set the correct access rights.
moeand do everything else from there.
mo-create-publicto update the public data available to contestants according to the contents of the
mo-create-testusersto update the home directory of the
Moe can either take care of the home directories of contestants or use an existing infrastructure. In the former case, you need to do the following:
CT_UID_MAXin the top-level config file. (The evaluator users described above should be outside this range!).
mo00:x:65100:65100:MO Contestant 00:/aux/mo/users/mo00/mo00:/bin/bash ... mo99:x:65199:65199:MO Contestant 99:/aux/mo/users/mo99/mo99:/bin/bash
mo00:x:65100: ... mo99:x:65199:
bin/mo-create-loginsscript to automate this process, including printing of leaflets with passwords, but you will probably need to customize the script.)
bin/mo-create-contestantsas root to create the home directories. (The permissions are set up so that the contestants cannot see each other's directory even if they want. However you still need to make sure that there is no directory all of them can write to, like the system-wide
/tmp. In our contest, the users work on their own machines and only the home directories are shared across the network, so this problem doesn't arise.)
limits.conffor that, because
sshdapplies the limits as root, so you either limit root or the limits don't work at all. In such cases, modify
if [ $UID -ge 65100 -a $UID -le 65199 ] ; then ulimit -Sc 8192 # core file size ulimit -SHu 32 # processes ulimit -SHn 256 # max open files ulimit -SHv 262144 # max virtual memory fi