forked from springhack/alxw_judge_core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathInstall.sh
executable file
·29 lines (26 loc) · 925 Bytes
/
Install.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/bash
install()
{
mkdir -p /home/AJC/runtime
cp -rvf data /home/AJC/
cp -rvf ajcserver /home/AJC/
cp -rvf ajcserver/ajcd /etc/init.d/
cp -rvf libs /home/AJC/
cp -rvf vj_root/* /var/www/html/alxwvj/
gcc src/compiler.c -o /home/AJC/ajcserver/compiler
chmod -R 777 /home/AJC
}
help()
{
echo 'AJC (Alxwvj judge core) module for Alxwvj'
echo 'Create by SpringHack'
echo 'https://github.com/springhack/alxwvj_judge_core.git'
echo 'All data are located at /home/AJC'
echo '==> "sudo ./Install.sh install" to install'
echo '==> Before run you have to setup lo-runner and install python-mysqldb'
echo '==> Edit "Config.Daemon.php", add "AJC" at "OJ_LIST", add prefix "" as AJC prefix !!!'
echo '==> Browse "AJC_ProblemManager.php" as admin to initial system !!!'
echo '==> Edit "/home/AJC/ajcserver/config.py" change db config !!!'
echo '==> "cd /home/AJC/ajcserver && ./start.sh" to run'
}
$1