# Copy to .env and edit. Every value here is the default unless stated otherwise. # The first-run walkthrough lives in the README; start there. # # Reminder: docker compose reads this file when a container is CREATED. After changing anything, # run `docker compose up -d --force-recreate` — a plain `restart` keeps the old values. ### Garmin account ########################################################### # Required. GARMIN_EMAIL=you@example.com # Only needed for `docker compose run --rm garmin-connector login`. Once a session is stored you can # remove it. Both variables also accept a _FILE variant pointing at a Docker secret, e.g. # GARMIN_PASSWORD_FILE=/run/secrets/garmin_password GARMIN_PASSWORD= # Garmin China. #GARMIN_IS_CN=false ### Where things live ######################################################## # Dreeve's watch folder, inside the container. Map it to the real one in docker-compose.yml. #WATCH_DIR=/watch # The ledger: which activities have already been fetched. Losing it means downloading everything again. #STATE_DIR=/state # The Garmin session. Keep this volume and you should never have to log in twice. #GARMINTOKENS=/tokens ### What to fetch ############################################################ # Required on the first run: how far back to reach. A date (2026-01-01), an ISO instant, # a relative offset (-30d, 720h) or 'now'. Resolved once and then remembered, so a restart # does not skip activities recorded while the container was down. SINCE=-30d # Only these activity types, comma separated, e.g. cycling,running. Empty means everything. # Widening this later picks up activities that were previously ignored. #ACTIVITY_TYPES= # Re-list the last few days every cycle, to catch watches that synced late and activities # edited after the fact. #LOOKBACK_DAYS=7 ### Pace ###################################################################### # Seconds between cycles. A watch syncs to Garmin minutes to hours after an activity, so hourly # is ample — Dreeve then imports within five minutes. #POLL_INTERVAL=3600 # Randomises the interval by ±this percentage, so every deployment of this image does not hit # Garmin on the same second of the hour. #POLL_JITTER_PCT=10 # The safety feature that matters most on day one. A first run against years of history is # hundreds of downloads; this spreads them over several cycles instead of asking for everything # at once and getting the account rate-limited. The remainder shows up in /status as a backlog. #MAX_DOWNLOADS_PER_CYCLE=25 # Pause between downloads. Garmin is far more forgiving of a slow client than a busy one. #DOWNLOAD_DELAY_SECONDS=2 # After a 429 the interval backs off exponentially, up to this many seconds (6 hours). #MAX_BACKOFF_SECONDS=21600 ### Files ##################################################################### # Manually entered and some indoor activities have no FIT file. Dreeve imports TCX and GPX too, # so those are fetched in that format instead. Set to 'none' to record them as having no file. #FALLBACK_FORMAT=tcx # What to do when the file is already in the watch folder: skip or overwrite. #ON_CONFLICT=skip # How many times an activity may fail before it is left alone. #MAX_ATTEMPTS=5 ### Authentication ############################################################ # The daemon never logs in by itself: repeated logins are what get an account rate-limited. # Setting this to true permits exactly ONE password login per container start, for accounts # without multi-factor authentication that want fully unattended setup. Everyone else runs # `docker compose run --rm garmin-connector login` once. #ALLOW_PASSWORD_LOGIN=false ### Operations ################################################################ # Serves /healthz and /status. Set to 'off' to disable, in which case the healthcheck falls # back to the heartbeat file in STATE_DIR. #HTTP_ADDR=0.0.0.0:8080 # 0 runs forever. Anything else runs that many cycles and exits, which is useful for testing. #MAX_CYCLES=0 # List what would be downloaded, download nothing and leave the ledger untouched. #DRY_RUN=false #LOG_LEVEL=info #LOG_FORMAT=text # Ownership of the files this connector writes. Set both to the uid/gid Dreeve runs as, or # leave them unset to run as root. #PUID=1000 #PGID=1000 #UMASK=022 TZ=Europe/Brussels