https://github.com/averagemarcus/docker-lighthouse
Run Google's lighthouse tests against a given website using the magic of Docker
https://github.com/averagemarcus/docker-lighthouse
docker hacktoberfest lighthouse test
Last synced: 3 months ago
JSON representation
Run Google's lighthouse tests against a given website using the magic of Docker
- Host: GitHub
- URL: https://github.com/averagemarcus/docker-lighthouse
- Owner: AverageMarcus
- Created: 2018-05-14T16:29:15.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2019-12-12T02:18:41.000Z (over 6 years ago)
- Last Synced: 2025-04-06T05:43:35.313Z (over 1 year ago)
- Topics: docker, hacktoberfest, lighthouse, test
- Language: JavaScript
- Homepage: https://hub.docker.com/r/averagemarcus/lighthouse/
- Size: 6.84 KB
- Stars: 0
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# docker-lighthouse
Run Google's lighthouse tests against a given website using the magic of Docker
## Example Usage
**Simple score**
```
❯ docker run -e URL=https://bbc.co.uk averagemarcus/lighthouse
Running Lighthouse against https://bbc.co.uk
Lighthouse results for https://bbc.co.uk
performance=57.88%
pwa=45.45%
accessibility=93.26%
best-practices=75.00%
seo=80.00%
```
**JSON Results**
```
❯ docker run -e URL=https://bbc.co.uk -v $(pwd)/results:/lighthouse-results averagemarcus/lighthouse
Running Lighthouse against https://bbc.co.uk
Lighthouse results for https://bbc.co.uk
performance=57.88%
pwa=45.45%
accessibility=93.26%
best-practices=75.00%
seo=80.00%
❯ ls results
2018-05-14T16:43:07.959Z.json latest.json
```
## Extending this image
```dockerfile
FROM averagemarcus/lighthouse
ENTRYPOINT /docker-entrypoint.sh && ls /lighthouse-results
```
## Generating lighthouse badges
To have [lighthouse badges](https://github.com/ebidel/lighthouse-badge) automatically created, pass in `-e withBadges=true` and a mount volume when running. E.g.
```
❯ docker run -e URL=https://bbc.co.uk -e withBadges=true -v $(pwd)/results:/lighthouse-results averagemarcus/lighthouse
```