在哪里可以看到HTML日志?

时间:2018-09-18 08:28:36

标签: docker sitespeed

如果我在docker中运行sitespeed并获得以下输出:

Google Chrome 63.0.3239.84
Mozilla Firefox 54.0.1
[2017-12-27 18:10:01] INFO: Versions OS: linux 4.9.49-moby nodejs: v8.9.1 sitespeed.io: 6.2.2 browsertime: 2.1.2 coach: 1.1.1
[2017-12-27 18:10:02] INFO: Starting chrome for analysing https://www.google.com/ 3 time(s)
[2017-12-27 18:10:02] INFO: Testing url https://www.google.com/ run 1
[2017-12-27 18:10:18] INFO: Testing url https://www.google.com/ run 2
[2017-12-27 18:10:29] INFO: Testing url https://www.google.com/ run 3
[2017-12-27 18:10:40] INFO: 18 requests, 584.40 kb, backEndTime: 158ms (±6.42ms), firstPaint: 321ms (±3.32ms), firstVisualChange: 389ms (±7.78ms), DOMContentLoaded: 376ms (±3.63ms), Load: 529ms (±91.22ms), speedIndex: 477 (±9.23), visualComplete85: 422ms (±7.90ms), lastVisualChange: 2.65s (±137.82ms), rumSpeedIndex: 321 (±3.32) (3 runs)
[2017-12-27 18:10:43] INFO: HTML stored in /sitespeed.io/reports
[2017-12-27 18:10:43] INFO: Finished analysing https://www.google.com/

HTML日志存储在哪里? '/sitespeed.io/reports',我不确定该去哪里访问。

1 个答案:

答案 0 :(得分:0)

Docker hub页面上的示例说:

docker run --shm-size=1g --rm -v "$(pwd)":/sitespeed.io sitespeedio/sitespeed.io http://www.sitespeed.io/ -b chrome
  • 命令的--rm部分表示容器完成后将其删除。因此,您将无法“进入”容器并访问结果,但是...
  • -v "$(pwd)":/sitespeed.io部分的意思是

    • -v:创建了volume
    • "$(pwd)":在您的工作目录中
    • 指向容器的/sitespeed.io文件夹

实际上,这意味着,如果您在名为/my-docker-tests的目录中运行上述命令(尽管已删除了容器),则可以在主机文件系统上的{ {1}}

enter image description here