Summary
Add backend/config/config.example.yml as the canonical configuration template.
Ensure structure matches config.Config in backend/config/config.go:
gemini, jwt, and smtp should be top-level keys (siblings of server, database, and googleOAuth).
Why
The previous example incorrectly nested these keys under database, causing cfg.Gemini.ApiKey to be empty and resulting in the error:
“Failed to initialize Gemini client: You need an auth option to use this client.”
Details
- Adds placeholders for all secrets — no real credentials.
- Keeps
database.uri unchanged (placeholder only).
- Aligns YAML structure with Go config parsing logic.
How to Verify
- Populate the secrets in
config.example.yml.
- Run the backend.
- The Gemini client should successfully initialize using
cfg.Gemini.ApiKey.
Notes
Consider adding backend/config/config.prod.yml to .gitignore to prevent committing secrets in local setups.