# order-export

Nightly job that dumps yesterday's rows from the orders database to CSV and
uploads them to S3, so the finance spreadsheets can pull from one place.

- `export.py` does the work. Settings come from `.env` in this directory.
- `crontab.txt` is what is installed for the `export` user (runs at 02:15).
- Output goes to `s3://orderexport-nightly-4kq9/daily/YYYY/MM/DD/<table>.csv`.
- Logs are written to `logs/`, one file per month.

Exports older than 2026 were moved to the archive bucket and are no longer
written by this job. How the archive works is in `notes/handover.txt`.

Requirements are in `requirements.txt` (Python 3.11).
