2023-06-02 14:05:20 +00:00
|
|
|
import { ConvictSchema } from "./types.js";
|
2023-02-13 12:41:30 +00:00
|
|
|
|
|
|
|
|
export interface IMetricsConfig {
|
|
|
|
|
address: string;
|
|
|
|
|
port: number;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export const MetricsConfig: ConvictSchema<IMetricsConfig> = {
|
|
|
|
|
address: {
|
|
|
|
|
doc: "The ip address to bind the prometheus metrics to",
|
|
|
|
|
format: "ipaddress",
|
|
|
|
|
default: "127.0.0.1",
|
|
|
|
|
env: "METRICS_ADDRESS",
|
|
|
|
|
},
|
|
|
|
|
port: {
|
|
|
|
|
doc: "The port to bind the prometheus metrics to",
|
|
|
|
|
format: "port",
|
|
|
|
|
default: 3002,
|
|
|
|
|
env: "METRICS_PORT",
|
|
|
|
|
arg: "port",
|
|
|
|
|
},
|
|
|
|
|
};
|