2.4 Drop sample configs in repo root

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-07 14:31:16 +02:00
parent 0dc0da8de1
commit 0a936a9f04
3 changed files with 48 additions and 1 deletions

View File

@@ -87,7 +87,7 @@ Each type lives in `src/FrameProcessor/Domain/`. Tests in `tests/FrameProcessor.
- On `OnChange`: log warning, skip invalid frame, keep valid ones serving (`PLAN.md` line 130, `CLAUDE.md` "frames.json reload asymmetry"). - On `OnChange`: log warning, skip invalid frame, keep valid ones serving (`PLAN.md` line 130, `CLAUDE.md` "frames.json reload asymmetry").
- Add a `FramesRegistry` service that exposes `TryGetByName(FrameName)` / `TryGetByMac(MacAddress)` over the current valid set. - Add a `FramesRegistry` service that exposes `TryGetByName(FrameName)` / `TryGetByMac(MacAddress)` over the current valid set.
### [ ] 2.4 Drop sample configs in repo root ### [x] 2.4 Drop sample configs in repo root
- `appsettings.json` from `PLAN.md` §"Settings schemas". - `appsettings.json` from `PLAN.md` §"Settings schemas".
- `frames.json` with one example frame (Spectra 6 palette). - `frames.json` with one example frame (Spectra 6 palette).
- **DoD:** Service starts and logs the loaded frames; an invalid `frames.json` fails startup with a clear error. - **DoD:** Service starts and logs the loaded frames; an invalid `frames.json` fails startup with a clear error.

28
appsettings.json Normal file
View File

@@ -0,0 +1,28 @@
{
"Mqtt": {
"Host": "mosquitto",
"Port": 1883,
"ClientId": "frame-processor",
"Username": null,
"Password": null,
"UseTls": false,
"BaseTopic": "frames",
"PublishQos": 1,
"RetryBackoffSeconds": [1, 2, 5, 15, 60]
},
"ApiKey": "change-me",
"Storage": {
"ImageDirectory": "/data/images"
},
"UrlFetch": {
"MaxBytes": 52428800,
"TimeoutSeconds": 30,
"MaxRedirects": 3
},
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
}
}

19
frames.json Normal file
View File

@@ -0,0 +1,19 @@
{
"Frames": [
{
"name": "living-room",
"mac": "AA:BB:CC:DD:EE:FF",
"resolution": { "width": 1600, "height": 1200 },
"orientation": "landscape",
"dithering": "floyd-steinberg",
"palette": [
{ "name": "black", "color": "#1F2226", "deviceColor": "#000000" },
{ "name": "white", "color": "#B9C7C9", "deviceColor": "#FFFFFF" },
{ "name": "blue", "color": "#233F8E", "deviceColor": "#0000FF" },
{ "name": "green", "color": "#35563A", "deviceColor": "#00FF00" },
{ "name": "red", "color": "#62201E", "deviceColor": "#FF0000" },
{ "name": "yellow", "color": "#C1BB1E", "deviceColor": "#FFFF00" }
]
}
]
}