DISCLAIMER: As-of 2021, this product does not have a free support team anymore. If you want this product to be maintained, please support on Patreon.
(This product is available under a free and permissive license, but needs financial support to sustain its continued improvements. In addition to maintenance and stability there are many desirable features yet to be added.)
THIS REPOSITORY IS AUTO-UPDATED BY GITHUB-RELEASE-NOTIFIER (https://github.com/femtopixel/github-release-notifier)
Lighthouse analyzes web apps and web pages, collecting modern performance metrics and insights on developer best practices.
This image is greatly inspired from Justin RIBEIRO's work
docker run --rm --name lighthouse -it -v /path/to/your/report:/home/chrome/reports femtopixel/google-lighthouse <your_site_url> <optional_args>
With <you_site_url>
url to your site (e.g. http://www.google.com). You can pass args AFTER the url
if you want to.
For example, you can export as json with this command:
docker run --rm --name lighthouse -it -v /path/to/your/report:/home/chrome/reports femtopixel/google-lighthouse http://www.google.com --output json
You can specify CHROME_FLAGS
environment variable (-e
parameter in your docker command) to be used in chrome-flags parameter. (default: --headless --disable-gpu --no-sandbox
)
Further reading on Google Lighthouse
- Error while writing files
Runtime error encountered: { Error: EACCES: permission denied, open '/home/chrome/reports/myawesome_site_admin_heavypage.report.json'
errno: -13,
code: 'EACCES',
syscall: 'open',
path: '/home/chrome/reports/myawesome_site_admin_heavypage.report.json' }
Make sure your folder has the write right for others (chmod o+w)
- Now it supports taking a link to a list as an argument instead of a local file path
- It also exports JSON in addition to HTML Commands helpful for the customizied version.
docker build . -t lighthouse:0.1;
docker run --rm --name lighthouse -it -v $PWD/output:/home/chrome/reports lighthouse:0.1 'https://drive.google.com/uc?id=1UIkD8mVbtvU2vNuILtjaJt-fteKFSlMh'