Skip to content

Commit

Permalink
Merge pull request #3 from freight-hub/remove-npm-scope
Browse files Browse the repository at this point in the history
Move the NPM package out of @freighthub NPM scope
  • Loading branch information
danopia authored Feb 3, 2021
2 parents 8b66378 + abb0b9a commit 2a6e18c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
17 changes: 5 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# @freighthub/verdaccio-openmetrics
# verdaccio-openmetrics

> Verdaccio plugin exposing an OpenMetrics/Prometheus endpoint with health and traffic metrics
Expand All @@ -21,28 +21,21 @@ There's also an option to collect NodeJS runtime metrics
A further option will be to infrequently collect statistics about the database,
however it's not clear yet what will be interesting to expose there.

## plugin name
## config

Note that this Verdaccio plugin is published within a package scope.
To load the plugin from a Verdaccio config, specify the full name:
If no extra config is given, HTTP request metrics will be exposed at `:9090/metrics`.

```yaml
middlewares:
'@freighthub/verdaccio-openmetrics':
openmetrics:
enabled: true
```
This works around the automatic `verdaccio-` prefix that Verdaccio expects.

## config

If no extra config is given, HTTP request metrics will be exposed at `:9090/metrics`.

If you want additional metrics, for example runtime and database metrics:
```yaml
middlewares:
'@freighthub/verdaccio-openmetrics':
openmetrics:
enabled: true
collect_runtime: true
collect_database: true
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@freighthub/verdaccio-openmetrics",
"name": "verdaccio-openmetrics",
"version": "0.1.0",
"description": "Verdaccio plugin exposing an OpenMetrics/Prometheus endpoint with health and traffic metrics",
"main": "lib/index.js",
Expand Down

0 comments on commit 2a6e18c

Please sign in to comment.