Demo Docker Microservices Provisioning App written in NodeJS
JavaScript
Latest commit 39112b6 Sep 24, 2015 @jbcpollak typo
Permalink
Failed to load latest commit information.
app
examples
.gitignore
.node-version
INSTRUCTIONS.md
README.md
index.js
package.json

README.md

Introduction

This project executes arbitrary JavaScript code within the context of a Docker container.

It receives the code and a single parameter in an HTTP POST request, creates a docker container, executes the code in the container, and then returns the result over the same POST request.

I consider this at the proof-of-concept stage. I figured out how to do all the basic requirements, but I don't consider the project up to professional standards. For specifics, see the Remaining Work section below. For an idea of a more polished project, please see:

ReactJS Example App

Usage

$ npm start
$ curl -F "app=@examples/script2.js" -F param=4 http://veterok.local:3000/process

Note: It looks like the provided script2.js is a duplicate of script1.js.

Remaining Work

  • Automated Testing, Continuous Integration, etc
  • More flexible parameter handling
  • Authentication on HTTP requests
  • File System Security - Right now all spaces are readable by all users
  • General Cleanup - Code organization and conventions, promises vs callbacks, etc

Articles I read while implementing this

Dependencies