https://github.com/exhuma/pgflux-origin
Monitoring Script for PostgreSQL and InfluxDB
https://github.com/exhuma/pgflux-origin
Last synced: 11 months ago
JSON representation
Monitoring Script for PostgreSQL and InfluxDB
- Host: GitHub
- URL: https://github.com/exhuma/pgflux-origin
- Owner: exhuma
- Created: 2021-10-03T11:13:33.000Z (over 4 years ago)
- Default Branch: develop
- Last Pushed: 2021-10-03T15:49:54.000Z (over 4 years ago)
- Last Synced: 2025-01-30T12:32:48.559Z (over 1 year ago)
- Language: Python
- Size: 33.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- Changelog: changelog.in
Awesome Lists containing this project
README
pgflux
======
A simple Python utility to send PostgreSQL metrics to InfluxDB
Development
===========
* Set up development environment::
fab develop
* Run a docker container for testing::
docker run --rm \
-e POSTGRES_PASSWORD=mys3cr37passw0rd \
-p :5432 \
postgresql:latest
* Create a ``.env`` file (use ``.env.template`` as guide)::
PGFLUX_DSN=postgresql://postgres:mys3cr37passw0rd@localhost:/postgres
* Run the tests::
./env/bin/pytest
Setting up Influx for Testing
=============================
::
docker run \
-p 8086:8086 \ ✓
--rm \
--name influxdb \
influxdb:1.8
docker exec -ti influxdb influx
> CREATE DATABASE postgres_stats