X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;ds=inline;f=bin%2Fmo-install;h=88a0fc684910541d2225e05b3b4429895fc592df;hb=895a884dcad1458941714db1d0552097aa8366a3;hp=966c3fdef487fbd73065ff81b7cfa741a13a668f;hpb=3bebe650c10dcae0926aef74bb5ccb95c6c4e409;p=moe.git diff --git a/bin/mo-install b/bin/mo-install index 966c3fd..88a0fc6 100755 --- a/bin/mo-install +++ b/bin/mo-install @@ -7,41 +7,32 @@ make H=`pwd` -# mo-eval home +# The eval directory cd $MO_ROOT rm -rf eval mkdir eval chgrp $EVAL_GROUP eval -chmod 550 eval +chmod 755 eval cd eval -echo "Creating $EVAL_USER" -mkdir $EVAL_USER -cd $EVAL_USER -cp -a $H/* . -mv bin/profile .profile -chmod +x bin/* -cd .. -chown -R $EVAL_USER.$EVAL_GROUP $EVAL_USER -chmod 700 $EVAL_USER - -( cd $EVAL_USER ; bin/mo-create-testusers ) - -# common + +# mo-eval home +bin/mo-create-eval + +# testusers +( cd eval && bin/mo-create-testusers ) + +# mo-submit home +if [ -n "$REMOTE_SUBMIT" ] ; then + mkdir submit + if [ -d ~/.ssh ] ; then echo "Copying SSH configuration from ~/.ssh" ; cp -a ~/.ssh submit/ ; fi + ( cd $H && bin/mo-create-submit ) +fi + +# create public cd $MO_ROOT echo "Creating public" rm -rf public mkdir public -cd public -cp -a $H/bin $H/config . -mkdir problems -cp -a $H/public/* bin/ -chmod +x bin/* -cd .. -chown -R $EVAL_USER.$EVAL_GROUP public -chmod 755 public - -# SSH keys (FIXME) -#echo "Copying SSH keys" -#mkdir $EVAL_USER/.ssh -#cp ~mj/.ssh/authorized_keys $EVAL_USER/.ssh/ -#chown -R $EVAL_USER $EVAL_USER/.ssh + +# populate public +( cd eval/eval ; bin/mo-create-public )