Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kazuma512/micro-cluster

Micro-Cluster is an open-source library for distributed computing and data processing. It allows you to create a cluster of small, low-cost machines that work together to perform large-scale computations or analyses.
https://github.com/kazuma512/micro-cluster

javascript kazuma512 micro nodejs

Last synced: about 1 month ago
JSON representation

Micro-Cluster is an open-source library for distributed computing and data processing. It allows you to create a cluster of small, low-cost machines that work together to perform large-scale computations or analyses.

Awesome Lists containing this project

README

        

# micro-cluster

[![XO code style](https://img.shields.io/badge/code_style-XO-5ed9c7.svg)](https://github.com/sindresorhus/xo)

Run multiple `micro` servers and a front proxy at a time, with a simple configuration file.

## Example

Create a config file like the following.

```js
export default {
services: {
myService: {
path: 'index.js',
env: { NODE_ENV: 'production' }
},
woot: 'woot.js'
},

locations: {
'^/path-regex/to/serve/?$': {
rewrite: ['^(.*)$', '$1/rewritten'],
proxySetHeaders: { 'X-CUSTOM-HEADER': '1' },
proxy: 'myService'
}
'^/woot/?$': 'woot'
}
}
```

Run servers.

```bash
$ micro-cluster -p 3000 app.js
```