mirror of
https://github.com/tiennm99/keepalive.git
synced 2026-10-11 03:13:31 +00:00
Consolidates the *-keepalive family (redis, valkey, postgresql, mysql, mongodb, couchbase) into a single binary with a runtime DB_TYPE dispatch and an Adapter interface. Original repos archived with a pointer here.
29 lines
774 B
Bash
29 lines
774 B
Bash
# Pick one of: redis, valkey, postgresql, mysql, mongodb, couchbase
|
|
DB_TYPE=redis
|
|
|
|
# Optional: tick interval (e.g. 30s, 1m, 5m). Defaults to 1m.
|
|
# INTERVAL=1m
|
|
|
|
# --- redis / valkey ---
|
|
REDIS_URL=redis://default@127.0.0.1:6379
|
|
# VALKEY_URL=valkey://default@127.0.0.1:6379
|
|
|
|
# --- postgresql ---
|
|
# SERVICE_URI=postgres://user:pass@host:5432/dbname?sslmode=require
|
|
|
|
# --- mysql ---
|
|
# DATA_SOURCE_NAME=user:pass@tcp(host:3306)/dbname
|
|
|
|
# --- mongodb ---
|
|
# MONGODB_URI=mongodb+srv://user:pass@cluster.mongodb.net
|
|
# MONGODB_DATABASE=keepalive
|
|
# MONGODB_COLLECTION=counter
|
|
|
|
# --- couchbase ---
|
|
# COUCHBASE_CONNECTION_STRING=couchbases://cb.host
|
|
# COUCHBASE_USERNAME=
|
|
# COUCHBASE_PASSWORD=
|
|
# COUCHBASE_BUCKET_NAME=
|
|
# COUCHBASE_SCOPE_NAME=_default
|
|
# COUCHBASE_COLLECTION_NAME=_default
|