AstrBot
AstrBot copied to clipboard
[Bug]强制启用https无需配置证书导致报错关闭
What happened / 发生了什么
系统配置启用https后,若未配置证书则容器会在启动后立即报错关闭,无法进入webui
Reproduce / 如何复现?
系统配置启用https且未配置证书
AstrBot version, deployment method (e.g., Windows Docker Desktop deployment), provider used, and messaging platform used. / AstrBot 版本、部署方式(如 Windows Docker Desktop 部署)、使用的提供商、使用的消息平台适配器
docker部署
OS
Linux
Logs / 报错日志
raise ValueError( ValueError: dashboard.ssl.enable 为 true 时,必须配置 cert_file 和 key_file。 sys:1: RuntimeWarning: coroutine 'AstrBotCoreLifecycle.start' was never awaited
Are you willing to submit a PR? / 你愿意提交 PR 吗?
- [x] Yes!
Code of Conduct
- [x] I have read and agree to abide by the project's Code of Conduct。
Hi @1rua! I'm Dosu and I’m helping the AstrBot team.
这是一个已知问题。当 dashboard.ssl.enable 设置为 true 但未配置证书时,服务器启动会失败。
临时解决方案:编辑 data/cmd_config.json,禁用 SSL:
{
"dashboard": {
"ssl": {
"enable": false
}
}
}
PR #5516 已经实现了前后端验证,可以在保存配置时阻止用户设置无效的 SSL 配置。如果你愿意提交 PR,可以参考该 PR 的实现方式添加更优雅的处理逻辑。
To reply, just mention @dosu.
Share context across your team and agents. Try Dosu.