# cujoblaunch

> helper library to launch jobs on CuToken Decentralized cloud computing ecosystem

Latest version **1.0.0** (published 2018-03-28) · ISC license · 0 weekly downloads

## Install

```sh
npm install cujoblaunch
pnpm add cujoblaunch
yarn add cujoblaunch
bun add cujoblaunch
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2018-03-28 |
| First published | 2018-03-28 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 8.6 KB |
| Known vulnerabilities | 0 (+3 in 3 direct dependencies) |
| Install scripts | no |
| Author | cutoken.io |
| Maintainers | cutoken |
| Keywords | cutoken, cloud, computing, cloud |

## Links

- npm: https://www.npmjs.com/package/cujoblaunch
- npm.io page: https://npm.io/package/cujoblaunch

## Dependencies (4)

- [http](https://npm.io/package/http.md) 0.0.0
- [uuid](https://npm.io/package/uuid.md) ^3.2.1
- [agenda](https://npm.io/package/agenda.md) ^1.0.3
- [request](https://npm.io/package/request.md) ^2.83.0

## Recent versions

- 1.0.0 (latest) — 2018-03-28

## README

# cuJobLaunch - quick start guide

### Launch your first compute job on cuToken cloud

``` javascript
var cjl = require("cuJobLaunch");

// set healthcheck to re-launch instances as needed
// pathToHealthCheck, subString to find in the response
// How frequently heath check needs to be performed
cjl.setHCConfig("/", "UnBlockify", 60000);

// provide necessary configuration of the compute job
// cutokensPerInstance, instanceTime, instanceImage, minInstancesNeeded, restClientIP(leave empty for local miner), portList, callBackWithNodeUp, callBackWithNodeDown
cjl.setConfig(1, 5*60, 'https://cloud.cutoken.io/curatedTemplates/UnBlockify/1/docker-compose.yml', 1, '', '80'
, function(val){
  console.log("node is up: "  + val["details"][0].resourceName); 
}
, function(val){
  console.log("node is down: "  + val["details"][0].resourceName); 
});

// Start the cluster. This will post compute jobs as needed to
// the cutoken cloud to maintain the cluster size as nodes 
// go up and down
cjl.startMonitoring()
```

---
_Source: https://npm.io/package/cujoblaunch · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
