Docker compose stack for running the dmoj judge.
-
Generate the configuration file
judges.confbash setup-judges-config.sh
-
Generate the files of each judge instance
bash init-judges-files.sh
-
Show the project directory tree to see the new files
tree -a -I .git .Using
-ato show hidden files and-Ito ignore the git hidden directory. -
Load the aliases in the current shell session
source bash_aliasesFor example, the alias
arcadia1dcallows the execution of thedocker composecommand in the environment of the judge one.
-
Build the judge image
docker compose build
-
Run the judge tests
docker compose run --rm app testThis command runs the available tests for each language run time.
-
Tag the latest image as active
bash tag-latest-image-as-active.sh
-
Define the judge key in the
.keyfile and review the environment variables in the.envfile.nano dmoj/judge1/.key
-
Review the environment variables substitution in the docker compose.
source bash_aliases arcadia1dc config -
Execute the judge, the
-doption runs it in the background.arcadia1dc up -d
-
See the logs for the judge, the
-foption waits for the judge output.arcadia1dc logs -f
-
Tag the latest image as active.
bash tag-latest-image-as-active.sh
-
Recreate the judges to use the latest image.
perl recreate-judges.pl
If a judge is not running, it is starting during this process.