igorrafael / express-cmd

URL centric API for runing commands (as subprocesses) using an express router

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

express-cmd

URL centric API for runing commands (as subprocesses) using an express router

Motivation

This package is meant for development servers where command line access may be restricted or where it might be desired to batch run commands via HTTP (eg: curl, wget, postman, etc).

I (@igorrafael) do not intend to develop any functionality that I do not need personaly. If you think some funcionality could make this more useful for you, feel free to create an "issue" where we can talk about enhancements.

Warning

If this package is left active on a production server (which you should not do) at the very least ensure that you have some middleware providing security to reduce the chances of misuse.

Future work

Some functionalities that could make this project more useful. Feel free to submit pull requests with enhancements, listed here or not.

  • Initial implementation
  • Tests
    • Automated testing
    • Linux
    • OSX
    • Windows
  • Options from child_process.spawn
    • cwd
    • env
    • detached
  • Process management
    • Processes termination
    • Exection log (/stats)
  • Error handling
  • Code style
    • Define beautification via the file .jsbeautifyrc
  • Publish to NPM
    • Test postinstall script
  • Documentation
    • Usage examples
  • Customization
    • Blacklisting (preventing commands)

About

URL centric API for runing commands (as subprocesses) using an express router

License:MIT License


Languages

Language:CoffeeScript 84.0%Language:JavaScript 16.0%