https://github.com/boyney123/garie-browsertime
Browsertime Garie plugin. Polls websites to checkout performance metrics also supports webhooks.
https://github.com/boyney123/garie-browsertime
garie performance web-performance
Last synced: about 1 month ago
JSON representation
Browsertime Garie plugin. Polls websites to checkout performance metrics also supports webhooks.
- Host: GitHub
- URL: https://github.com/boyney123/garie-browsertime
- Owner: boyney123
- License: mit
- Created: 2018-09-18T11:25:16.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-07-19T08:03:52.000Z (about 6 years ago)
- Last Synced: 2025-03-22T17:11:23.988Z (7 months ago)
- Topics: garie, performance, web-performance
- Language: JavaScript
- Homepage:
- Size: 14.7 MB
- Stars: 7
- Watchers: 3
- Forks: 9
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README

Tool to gather browsertime metrics and supports CRON jobs and webhooks.
**Highlights**
- Poll for browsertime performance metrics on any website and stores the data into InfluxDB
- Webhook support
- Generates web performance videos
- View all historic reports.
- Setup within minutes## Overview of garie-browsertime
Garie-browsertime was developed as a plugin for the [Garie](https://github.com/boyney123/garie) Architecture.
[Garie](https://github.com/boyney123/garie) is an out the box web performance toolkit, and `garie-browsertime` is a plugin that generates and stores browsertime data into `InfluxDB`.
`Garie-browsertime` can also be run outside the `Garie` environment and run as standalone.
If your interested in an out the box solution that supports multiple performance tools like `browsertime`, `google-speed-insight` and `lighthouse` then checkout [Garie](https://github.com/boyney123/garie).
If you want to run `garie-browsertime` standalone you can find out how below.
## Getting Started
### Prerequisites
- Docker installed
### Running garie-browsertime
You can get setup with the basics in a few minutes.
First clone the repo.
```sh
git clone git@github.com:boyney123/garie-browsertime.git
```Next setup you're config. Edit the `config.json` and add websites to the list.
```javascript
{
"cron": "00 00 */6 * * *",
"urls": [
{
"url": "https://www.comparethemarket.com"
},
{
"url": "https://www.bbc.co.uk"
},
{
"url": "https://www.cnn.com"
}
]
}
```Once you finished edited your config, lets build our docker image and setup our environment.
```sh
docker build -t garie-browsertime . && docker-compose up
```This will build your copy of `garie-browsertime` and run the application.
On start garie-browsertime will start to gather performance metrics for the websites added to the `config.json`.
## Viewing reports
Viewing browsertime reports is straight forward. Once you have your application running just go to `localhost:3000/reports` and you should see all the reports browsertime has generated.

## Webhook
Garie-browsertime also supports webhooks. You will need to `POST` to `localhost:3000/collect`.
**Payload**
| Property | Type | Description |
| -------- | ------------------- | ----------------------- |
| `url` | `string` (required) | Url to get metrics for. |**Payload Example**
```javascript
{
"url": "https://www.bbc.co.uk"
}
```## config.json
| Property | Type | Description |
| -------- | ------------------- | ------------------------------------------------------------------------------------ |
| `cron` | `string` (optional) | Cron timer. Supports syntax can be found [here].(https://www.npmjs.com/package/cron) |
| `urls` | `object` (required) | Config for browsertime. More detail below |**urls object**
| Property | Type | Description |
| -------- | ------------------- | ----------------------------------- |
| `url` | `string` (required) | Url to get browsertime metrics for. |