Metadata-Version: 2.1
Name: sgp30-exporter
Version: 0.2.1
Summary: UNKNOWN
Home-page: https://github.com/urbas/sgp30-exporter
Author: Matej Urbas
Author-email: matej.urbas@gmail.com
License: MIT license
Keywords: sgp30-exporter,air quality,prometheus,exporter
Platform: UNKNOWN
Description-Content-Type: text/markdown
License-File: LICENSE

# sgp30-exporter [![build-badge]](https://travis-ci.com/github/urbas/sgp30-exporter) [![pypi-badge]](https://pypi.org/project/sgp30-exporter/)

Exports air quality readings from Pimoroni SGP30 to Prometheus.

This exporter uses [pimoroni-sgp30] to obtain data.

## Installation

```bash
pip install sgp30-exporter
```

## Running

```bash
sudo sgp30-exporter
```

This will serve metrics at `http://0.0.0.0:9895/metrics`.

Note that `sudo` is required to give SGP30 read-write access to the `/dev/i2c` interface.

You can make Prometheus scrape these with this scrape config:

```yaml
scrape_configs:
  - job_name: "sgp30"
    static_configs:
      - targets: ["<the IP of your exporter host>:9895"]
        labels:
          location: "bedroom"
```

[build-badge]: https://travis-ci.com/urbas/sgp30-exporter.svg?branch=master
[pimoroni-sgp30]: https://github.com/pimoroni/sgp30-python
[pypi-badge]: https://badge.fury.io/py/sgp30-exporter.svg


# 0.2.1

- CLI help test assertion less picky about help format.

# 0.2.0

- Introduced the `sgp30-exporter` CLI application. Makes it easier to run this exporter.
- Exporting metrics on port `9895` by default.

# 0.1.2

- Bugfix: try to reconnect even if initialization failed.

# 0.1.1

- Bugfix: reconnect to the SGP30 device on I/O failure.

# 0.1.0

- Initial release.


