chilltrack-api / README.md
rairo's picture
Claude Sonnet 5
Move admin login to Google sign-in against an allow-list
f5bb54a
|
Raw History Blame Contribute Delete
1.36 kB
---
title: ChillTrack API
emoji: ❄️
colorFrom: blue
colorTo: gray
sdk: docker
pinned: false
---
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
ChillTrack is a cold-chain temperature logging API for Colcom. A technician
photographs a chiller/freezer's gauge or digital display, Gemini extracts the
reading, the technician confirms/edits it, and it's logged against one of the
12 fixed daily time slots (08:00 through 06:00, covering an 8am-to-8am shift).
## Environment variables
See `.env.example`. `Gemini` and `FIREBASE` are required; the app exits at
startup if either is missing.
`FIREBASE` should be the same service-account JSON already used for
`helenia-api`, so ChillTrack shares that Firebase project instead of
standing up a new one. Firestore collections are all prefixed `ctk_`, so
there's no risk of colliding with Helenia's own data in the same project.
`ADMIN_EMAILS` is a comma-separated list of Gmail addresses allowed into the
admin area. Admin access is granted by Google sign-in, not a password: the
first time an allow-listed address signs in with Google, the backend grants
it the admin role automatically. There is no separate bootstrap step. To add
another admin, add their address here and have them sign in.
## Local run
```
pip install -r requirements.txt
python main.py
```