UNPKG

cc-core-cli

Version:

Command Line Interface tool for generating project templates for the (Your Platform's Name) platform.

22 lines (18 loc) 458 B
import { Injectable, Logger } from "@nestjs/common"; import * as os from "os"; import { CONST } from "@shopstack/cc-core-lib/core"; @Injectable() export class AppService { private _isReady: boolean; init(): string { this._isReady = true; Logger.log(`CPU cores ${os.cpus().length}`, "OS"); return "health_check"; } healthCheck(): boolean { if (!CONST.HEALTH_CHECK) { throw new Error("not ready"); } return true; } }