ComputeEngine
A Docker based sandboxing mechanism to safely execute untrusted user code, built using goLang.
Install / Use
/learn @prashant-raghu/ComputeEngineREADME
ComputeEngine
A Docker based sandboxing mechanism to safely execute untrusted user code in an isolated environment and prevent remote code execution vulnerability and other nasty things one can think of.
How it works
For each code execution request here is what computeEngine does:
- Roll up a new Docker Container.
- Mount a shared Directory from main server to this Docker Container.
- Write the code to be executed along with execution instructions.
- Container Executes the code present in shared Directory.
- Result is written into a new file created by container witin the shared directory.
- Main server watches for creation of this file and once done Responds to user with the result.
Development
prerequisites: Docker and golang.
1) Build Docker Image from dockerfile
$ cd sandbox
$ docker image build -t sandbox:v1 .
2) Start the go server
$ go run main.go
3) Verify the deployment by navigating to:
127.0.0.1:5000
4) To try out the code execution part make a POST request to \execute with "code"(Js for now) in body of request:
127.0.0.1:5000/execute
Todos
- Add Timeout docker kill to executeHandler.
- Start writing Tests.
- Add multi Language Support.
License
MIT
Free Code, Hell Yeah!
Related Skills
node-connect
349.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
xurl
349.0kA CLI tool for making authenticated requests to the X (Twitter) API. Use this skill when you need to post tweets, reply, quote, search, read posts, manage followers, send DMs, upload media, or interact with any X API v2 endpoint.
prose
349.0kOpenProse VM skill pack. Activate on any `prose` command, .prose files, or OpenProse mentions; orchestrates multi-agent workflows.
frontend-design
109.4kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.


