continuous-integration - Google Lighthouse CI - LHCI 服务器可用于多个自动运行
问题描述
我正在尝试设置Lighthouse CIlhci autorun
,但多次运行时遇到问题。我查看了入门说明并查看了故障排除部分,但没有运气。
如何修改我的 LHCI 项目和 docker LHCI Server ( Docker Server ) 的配置,以便lhci autorun
针对最新的 Stash/Bitbucket 运行并且不给我:
Error: Unexpected status code 422
{"message":"Build already exists for hash \"18fcc3e730cc720756eba4b9a94a778b60d5e1e0\""}
at ApiClient._convertFetchResponseToReturnValue (/usr/local/lib/node_modules/@lhci/cli/node_modules/@lhci/utils/src/api-client.js:54:21)
at processTicksAndRejections (internal/process/task_queues.js:86:5)
WARNING: upload command failed.
assert command failed. Exiting with status code 1.
我只在第一次运行后获得默认提交显示的结果:
18fcc3e “测试(实用程序):支持 travis 构建上下文测试”
使用我尝试将我的项目配置为指向我的 Stash 存储库,但是在将其添加到我的 lighthouserc.json 后从项目向导设置生成的令牌在http://localhost:9001/applhci wizard
上不起作用。我错过了什么?
灯塔rc.json
{
"ci": {
"server": {
"port": 9001,
"storage": {
"storageMethod": "sql",
"sqlDialect": "sqlite",
"sqlDatabasePath": "/data/lhci.db"
}
},
"collect": {
"numberOfRuns": 2,
"url": [
"https://wwww.mydomain.ca/",
"https://www.mydomain.ca/page2",
]
},
"upload": {
"target": "lhci",
"serverBaseUrl": "http://localhost:9001",
"token": "38c17168748-c5f8-4744-b05d-3fdc97806adfabf"
}
}
}
解决方案
即使它失败了,它也会创建一个新的本地提交,允许我收集数据:
git commit --allow-empty -m '重新运行 CI' && git push
来自:https ://github.com/GoogleChrome/lighthouse-ci/blob/master/docs/troubleshooting.md
推荐阅读
- html - 我将如何从 HTML 按钮调用批处理命令
- javascript - 控制器中范围数据中的变量
- powershell - 将剪贴板中的文本通过管道传输到 Powershell 中的提示符
- docker - docker-compose yaml.parser.ParserError
- csv - SSIS 将空白日期时间列转换为 NULL 并解析输入
- typescript - 这个成语是否有一个名称,可以根据先前的值和结果计算新结果?
- spring - Spring5 - Reactor API - 发送顺序请求并将响应作为字符串获取
- google-apps-script - 重复功能直到满足某些条件?谷歌表格/日历 API
- r - 用 Rvest 抓取 Transfermarket
- mule - 从dataweave 2.0中的JSON消息中提取最大/最早日期