Kubernetes (k8s) probe services for Feathers exposed on /healthy and /ready
They will both return 404 and the text specified in the config file.
Will start to send 200 ok after app.set("status").ready = "OK"
is
executed
Installation of the npm
npm install @lpgroup/feathers-k8s-probe-services
In config/default.json
add the following.
{
"status": {
"ready": "NOT-STARTED"
}
}
In src/servies/index.js
const { ready, healthy } = require("@lpgroup/feathers-k8s-probe-services");
app.configure(ready);
app.configure(healthy);
In src/index.js
server.on("listening", async () => {
app.set("status").ready = "OK";
});
See contribute
MIT - See licence