What version of HAPI is running?
hapi version: 0.17.2
What platform is your computer?
Windows 11 24H2
What issue are you seeing?
在 docs/guide/installation.md 中,多处文档示例使用 hapi runner start --foreground(如 pm2、nohup、launchd、systemd 场景),但实际 CLI 源码 cli/src/commands/runner.ts 并未解析或实现该参数。实际运行 hapi runner start --foreground 时,runner 依然以 detached(后台)方式运行,--foreground 被忽略,导致行为与文档描述不符,易导致误用。
What steps can reproduce the bug?
- 按文档执行命令:
hapi runner start --foreground
- runner 实际依然以后台 detached 方式启动
- 查看对应 CLI 源码
cli/src/commands/runner.ts,未有 foreground 参数相关逻辑
What is the expected behavior?
- CLI 层支持
--foreground,可以不以 detached 方式启动并让进程保持前台运行,方便 systemd/supervisor/容器等进程管理工具集成
或
- 文档同步修正,移除/更正该参数用法,避免引起误导
Additional information
相关参考:
该问题会影响进程托管、自动重启、可观测性等生产级部署场景。
What version of HAPI is running?
hapi version: 0.17.2
What platform is your computer?
Windows 11 24H2
What issue are you seeing?
在 docs/guide/installation.md 中,多处文档示例使用
hapi runner start --foreground(如 pm2、nohup、launchd、systemd 场景),但实际 CLI 源码cli/src/commands/runner.ts并未解析或实现该参数。实际运行hapi runner start --foreground时,runner 依然以 detached(后台)方式运行,--foreground被忽略,导致行为与文档描述不符,易导致误用。What steps can reproduce the bug?
hapi runner start --foregroundcli/src/commands/runner.ts,未有 foreground 参数相关逻辑What is the expected behavior?
--foreground,可以不以 detached 方式启动并让进程保持前台运行,方便 systemd/supervisor/容器等进程管理工具集成或
Additional information
相关参考:
该问题会影响进程托管、自动重启、可观测性等生产级部署场景。