@ -65,20 +65,20 @@ console.info("Version: " + checkVersion.version);
// Dual-stack support for (::)
// Dual-stack support for (::)
// Also read HOST if not FreeBSD, as HOST is a system environment variable in FreeBSD
// Also read HOST if not FreeBSD, as HOST is a system environment variable in FreeBSD
let hostEnv = FBSD ? null : process . env . HOST ;
let hostEnv = FBSD ? null : process . env . HOST ;
let hostname = process. env . UPTIME _KUMA _HOST || args . host || hostEnv ;
let hostname = args. host || process. env . UPTIME _KUMA _HOST || hostEnv ;
if ( hostname ) {
if ( hostname ) {
console . log ( "Custom hostname: " + hostname ) ;
console . log ( "Custom hostname: " + hostname ) ;
}
}
const port = [ process. env . UPTIME _KUMA _PORT , process . env . PORT , args . port , 3001 ]
const port = [ args. port , process. env . UPTIME _KUMA _PORT , process . env . PORT , 3001 ]
. map ( portValue => parseInt ( portValue ) )
. map ( portValue => parseInt ( portValue ) )
. find ( portValue => ! isNaN ( portValue ) ) ;
. find ( portValue => ! isNaN ( portValue ) ) ;
// SSL
// SSL
const sslKey = process. env . UPTIME _KUMA _SSL _KEY || process . env . SSL _KEY || args [ "ssl-key" ] || undefined ;
const sslKey = args[ "ssl-key" ] || process. env . UPTIME _KUMA _SSL _KEY || process . env . SSL _KEY || undefined ;
const sslCert = process. env . UPTIME _KUMA _SSL _CERT || process . env . SSL _CERT || args [ "ssl-cert" ] || undefined ;
const sslCert = args[ "ssl-cert" ] || process. env . UPTIME _KUMA _SSL _CERT || process . env . SSL _CERT || undefined ;
const disableFrameSameOrigin = ! ! process . env . UPTIME _KUMA _DISABLE _FRAME _SAMEORIGIN || args [ "disable-frame-sameorigin" ] || false ;
const disableFrameSameOrigin = args [ "disable-frame-sameorigin" ] || ! ! process . env . UPTIME _KUMA _DISABLE _FRAME _SAMEORIGIN || false ;
// 2FA / notp verification defaults
// 2FA / notp verification defaults
const twofa _verification _opts = {
const twofa _verification _opts = {