-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
优化目前https使用mkcert过于麻烦问题 #8411
Comments
mkcert 生成的证书 在我电脑是合法的 感觉是不是跟生成有关系 |
我是直接安装完,然后跑dev,访问https://localhost:8000 页面会提示证书不合法,需要允许访问。 你有手动安装过这个证书吗? |
没有 |
1、mkcert 我这边也是合法的 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
问题
目前umi内部使用https会先去检查是否安装mkcert以及使用mkcert来生成证书,对于win linux 用户过于繁琐
解法
1、umi https 配置提供选项支持用户选择自动生成
2、自动生成 参考 vitejs/vite#6325 https://github.com/vitejs/vite/blob/main/packages/vite/src/node/certificate.ts
已知问题
目前无论是mkcert or vite 的方案生成的证书,在浏览器直接访问都是不安全的
文档内需要引导用户自己生成安全的证书通过 https.cert https.key 配置 https://github.com/vitejs/vite/blob/main/packages/vite/src/node/certificate.ts
或者使用umi生成证书方案时,允许临时证书访问
The text was updated successfully, but these errors were encountered: