Welcome to the Pixel Code Platform family of projects. This is the code execution server.
Pixel Code Platform is a self-hostable coding challenge platform. The backend is open to contribution!
This is a server exposing a REST API to execute code through various VMs/interpreters
Some VMs used as executors may not be free of privilege escalation exploit risks.
Because of this, I highly recommend running this server on a throwaway VPS
or hardware-based VM.
This server is meant to be used with pcp, but feel free to use it for any other purposes (as long as you are aware of the warning above.)
- JavaScript, using caoccao/Javet
- Python, using ninia/jep
- Lua, using luaj/luaj
Swagger is accessible through /docs
- POST
/Request body:Response body:{ "lang": "string", "code": "string" }{ "status": 0, "output": "string" }
Original README.md from Quarkus, which includes running instructions:
You can run your application in dev mode that enables live coding using:
./gradlew quarkusDevNOTE: Quarkus now ships with a Dev UI, which is available in dev mode only at http://localhost:8080/q/dev/.
The application can be packaged using:
./gradlew buildIt produces the quarkus-run.jar file in the build/quarkus-app/ directory.
Be aware that it’s not an über-jar as the dependencies are copied into
the build/quarkus-app/lib/ directory.
The application is now runnable using
java -jar build/quarkus-app/quarkus-run.jar.
If you want to build an über-jar, execute the following command:
./gradlew build -Dquarkus.package.type=uber-jarThe application, packaged as an über-jar, is now runnable using
java -jar build/*-runner.jar.
You can create a native executable using:
./gradlew build -Dquarkus.package.type=nativeOr, if you don't have GraalVM installed, you can run the native executable build in a container using:
./gradlew build -Dquarkus.package.type=native -Dquarkus.native.container-build=trueYou can then execute your native executable with:
./build/coxecude-1.0-SNAPSHOT-runner
If you want to learn more about building native executables, please consult https://quarkus.io/guides/gradle-tooling.