# workhive-caldav-sync Sync Workhive schedule shifts to a CalDAV calendar. Basic usage 1. Copy `.env.example` to `.env` and fill values (do NOT commit `.env`). 2. Run locally with Docker Compose (recommended): ```bash # build and run docker compose up --build # or run in background docker compose up --build -d # stop docker compose down ``` 3. Or run with Docker directly: ```bash docker build -t workhive-sync:latest . docker run --rm --env-file .env workhive-sync:latest ``` Notes - Secrets are read from environment via `python-dotenv` when running locally (.env file). - The script expects the website to provide times in the timezone set by `TIMEZONE` (default America/New_York). - Events are checked for duplicates by deterministic UID and summary+start match before creation. Container behavior - The container runs `sync.py` once immediately and then repeats every hour. - If you prefer a one-shot run (no loop), change the `CMD` in the `Dockerfile` to `python sync.py` or run the image with an override command. Files of interest: - [sync.py](sync.py) - [Dockerfile](Dockerfile) - [.env.example](.env.example) - [requirements.txt](requirements.txt) - [docker-compose.yml](docker-compose.yml)