Skip to content

An Online Judge based on MERN Stack, Spring Boot and Docker.

Notifications You must be signed in to change notification settings

meetpatel0963/Online-judge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Online-Judge

An Online-judge system based on Node and React (MERN Stack).

Features

  • Authentication and Authorization
  • Submit your code
  • Test your code
  • Results shows Time (Sec) and Memory (MB)
  • Verdicts
    • Time Limit Exceeded (TLE)
    • Memory Limit Exceeded (MLE)
    • Compilation Error (CE)
    • Runtime Error (RTE)
    • Wrong Answer (WA)
    • Accepted (AC)
  • See your submissions
  • Filter problems based on tags
  • Search problems by name
  • Dashboard for Statistics
  • Create Coding Problems
  • E-mail verification
  • Forgot password
  • Leaderboard

Supported Languages

  • C
  • C++ 11/14/17 (GCC)
  • Java 8
  • Python 3

Prerequisite

  • Docker Desktop
  • Node.js

Env Variables

In judge/config/config.js:

PORT = 5000
JWT_PRIVATE_KEY = <Your_JWT_Token>
BACK_SERVER_URL = <Spring_Server_URL>

Setup Locally

Make sure to install docker in your machine.

Start Docker Desktop

git clone https://github.com/meetpatel0963/Online-judge.git
cd online-judge

Client

In client/src/config/config.js:

Change BACK_SERVER_URL="http://localhost:<spring_server_port>"

Change JUDGE_URL="http://localhost:<judge_server_port>"

cd client
npm install
npm start

Server

Start Spring Boot Server

Change PATH_INIT={{Path to Server Directory}} in judge/judge.js

cd judge
mkdir submissions
npm install
cd docker
docker build -t <Image_Name> .
cd ..
npm start

Make sure to start Docker Desktop before the command npm start.

🎉 And that's it! You will now be able to visit http://localhost:3000/ URL and see your application up and running.

Snapshots

SignIn

SignIn

SignUp

SignUp

ProblemSet

Problem

Problem Page

Problem Problem

Code Editor

Problem

Results

Results

Add Problem Page

AddProblem AddProblem

User Submissions

My Submission

User Submission Modal

Modal

Dashboard Charts

Dashboard

Dashboard Charts

Dashboard

Thanks

  • I'd appreciate a star if you find this helpful.

License

MIT