github Drakonis96/statainer v0.9.20

5 hours ago

Database moves into a data directory · repo no longer ships a database

Changed

  • The database now lives in a dedicated data directory. Point configuration at a directory (DATA_DIR, default /app/data) instead of a .db file — statainer manages the users.db filename internally and creates it there on first start. The image pre-creates /app/data and sets DATA_DIR=/app/data; the bundled compose already mounts ./data:/app/data.
  • USERS_DB_PATH (file or directory) is still honored for backward compatibility and takes precedence over DATA_DIR.

Migration (existing users)

  • On startup, a database at the old /app/users.db location is moved into the data directory automatically, so upgrading users keep their accounts and settings. The move is best-effort, idempotent and never blocks startup.
  • Deployments already using the bundled compose (./data:/app/data) require no action — their database is already in the data directory.

Security

  • Removed the committed users.db (and a stray templates/users.db) from the repository. They contained a real admin password hash and were tracked in a public repo. They are now untracked and ignored; the database is only ever created at runtime. (Docker images were never affected — .dockerignore already excluded these files.)
  • Note: the old hash still exists in prior git history. Rotating the admin password is recommended if it was ever a real credential.

Tests

  • Full suite: 100 passed (+5 new tests covering data-dir resolution and the legacy database migration).

Docker images

  • drakonis96/statainer:v0.9.20 / :latest
  • drakonis96/dockerstats:v0.9.20 / :latest

Multi-arch: linux/amd64, linux/arm64.

Don't miss a new statainer release

NewReleases is sending notifications on new releases.