【问题标题】:RequestError Error: self signed certificate in certificate chain - Percy Visual TestsRequestError 错误:证书链中的自签名证书 - Percy Visual Tests
【发布时间】:2020-10-29 09:22:57
【问题描述】:

Percy 不适合我进行视觉测试。我收到一个错误 -

> percy exec -- node ./run-tests.js

[percy] RequestError Error: self signed certificate in certificate chain | Thu Oct 29 2020 14:46:52 GMT+0530 (India Standard Time)
[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.
[percy] percy has started.
Server is listening on http://localhost:8000

[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.
Terminate batch job (Y/N)? y

尝试了很多类似下面 (.npmrc) 的方法,但都没有奏效 -

  1. ca=
  2. strict-ssl=false
  3. registry=http://registry.npmjs.org/
  4. 设置代理和 https-proxy

【问题讨论】:

    标签: npm cypress browserstack


    【解决方案1】:

    对于我的组织,这是由我们的中间人网络过滤器造成的。要绕过它,您需要通过在 NODE_EXTRA_CA_CERTS 环境变量中设置文件的路径,将 NPM 指向您公司的 Web 过滤器证书的副本。

    证书需要导出为 Base64 格式。当您在文本编辑器中查看它时,您会在顶部和底部看到 BEGIN CERTIFICATE 和 END CERTIFICATE。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2012-08-24
      • 2017-12-18
      • 2015-09-08
      • 1970-01-01
      • 1970-01-01
      • 2022-06-16
      • 2019-01-23
      相关资源
      最近更新 更多