@@ -11,11 +11,15 @@ import { callback } from "awaiting";
1111import blocked from "blocked" ;
1212import { spawn } from "child_process" ;
1313import { program as commander , Option } from "commander" ;
14+
1415import basePath from "@cocalc/backend/base-path" ;
1516import {
1617 pghost as DEFAULT_DB_HOST ,
1718 pgdatabase as DEFAULT_DB_NAME ,
1819 pguser as DEFAULT_DB_USER ,
20+ pgConcurrentWarn as DEFAULT_DB_CONCURRENT_WARN ,
21+ hubHostname as DEFAULT_HUB_HOSTNAME ,
22+ agentPort as DEFAULT_AGENT_PORT ,
1923} from "@cocalc/backend/data" ;
2024import { trimLogFileSize } from "@cocalc/backend/logger" ;
2125import port from "@cocalc/backend/port" ;
@@ -352,14 +356,14 @@ async function main(): Promise<void> {
352356 )
353357 . option (
354358 "--agent-port <n>" ,
355- " port for HAProxy agent-check (default: 0 -- do not start)" ,
359+ ` port for HAProxy agent-check (default: ${ DEFAULT_AGENT_PORT } ; 0 means " do not start")` ,
356360 ( n ) => parseInt ( n ) ,
357- 0 ,
361+ DEFAULT_AGENT_PORT ,
358362 )
359363 . option (
360364 "--hostname [string]" ,
361- ' host of interface to bind to (default: "127.0.0.1")' ,
362- "127.0.0.1" ,
365+ ` host of interface to bind to (default: "${ DEFAULT_HUB_HOSTNAME } ")` ,
366+ DEFAULT_HUB_HOSTNAME ,
363367 )
364368 . option (
365369 "--database-nodes <string,string,...>" ,
@@ -407,9 +411,9 @@ async function main(): Promise<void> {
407411 )
408412 . option (
409413 "--db-concurrent-warn <n>" ,
410- " be very unhappy if number of concurrent db requests exceeds this (default: 300)" ,
414+ ` be very unhappy if number of concurrent db requests exceeds this (default: ${ DEFAULT_DB_CONCURRENT_WARN } )` ,
411415 ( n ) => parseInt ( n ) ,
412- 300 ,
416+ DEFAULT_DB_CONCURRENT_WARN ,
413417 )
414418 . option (
415419 "--personal" ,
0 commit comments