preethamb97 / competitive-programming-scalable-compilers-docker-load-balancer

competitive programming scalable compilers for execution with docker and NGINX load balancer
MIT License
2 stars 0 forks source link
compiler docker docker-compose load-balancer nginx server

competitive-programming-scalable-compilers-docker-load-balancer

to spin up all containers

sudo docker-compose down && sudo docker-compose up --build --force-recreate

Procedure to make compile post request

post request url http://localhost:8000/code_executor

form data with below params

user_id:3

execution_type:1

code_data param will contain buffer of file(for example code.py)

different execution types

1. python3

2. javascript

3. CPP

4. C

5. GOLANG

6. PHP

7. python2

this nginx load balancer uses round robin to spin up containers and distribute compiled code output to user.