"This data is great! Can we have a report every day?" 💀
Sometimes you need a quick and hacky way of querying and summarising data on a regular basis. cronsql
is a simple
Docker-enabled SQL query scheduler & reporting toolkit for analytics workloads.
Query, cron
strings, and auth details are defined in the config.yaml
file. The default settings are:
database:
host: database
user: postgres
password: postgres
database: postgres
port: 5432
query: |
SELECT *
FROM example
WHERE timestamp > NOW() - INTERVAL '30 seconds'
cron: "*/1 * * * *"
./run-test-harness.sh
spins up the default cronsql
image, a Postgres instance and a harness
service (which populates
the database instance).