Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 595 Bytes

README.md

File metadata and controls

25 lines (17 loc) · 595 Bytes

health route

meteor add panter:healthroute

simple package that adds a route __health for health checks

Custom health routes

You can define custom health checks like this:

import { customHealthChecks } from "meteor/panter:healthroute";

customHealthChecks({
  myCustomCheck: async () => {
    const success = await someAsyncTaskThatReturnsBoolean();
    return success;
  },
  someOtherCheck,
});

each of this checks should return true if everything is alright or return something else (or throw an error) otherwise.

The route will send a 503 if any health check fails.