Stats service
You'll need a database compatible with the MongoDB API.
If you are using CosmosDB your shard key has to be "system".
Post stats for given system
$ curl -v -H "Authorization: INSERT-JWT-TOKEN" --header "Content-Type: application/json" http://localhost:3000/stats/minelev -d '{"queue": "10", "done": "42"}'
Get stats for given system
$ curl -v http://localhost:3000/stats/minelev
[
{
"_id": "5936af1637fcfde27cf42a75",
"system": "minelev",
"queue": "0",
"done": "897"
}
]
Add local .env
MONGODB_CONNECTION=mongodb-connection-string
MONGODB_COLLECTION=mongodb-collection-name
MONGODB_NAME=mngodb-name
JWT_SECRET=jwt-secret
Start development environment
$ npm run dev
Configure now.json
Run the deployment script
$ npm run deploy
Do a tagged release