Found in the trial run for #260, on next at e8b4006.
buildConfig in internal/config/config.go reads PORT and DNSWATCHER_TLS_EXPIRY_WARNING with viper.GetInt, and DNSWATCHER_DEBUG, DNSWATCHER_MAINTENANCE_MODE and DNSWATCHER_SEND_TEST_NOTIFICATION with viper.GetBool. A value that does not parse becomes 0 or false, and dnswatcher starts with no error and nothing logged:
DNSWATCHER_TLS_EXPIRY_WARNING=abc, or -5, gives a warning period of 0 days, so no expiry warning is ever sent: a certificate would be warned about only after it expired, and an expired one fails the TLS check instead.
PORT=notaport starts the HTTP server on a random port ("addr":":0" in the log). The dashboard, the API and the image's HEALTHCHECK cannot reach it.
DNSWATCHER_MAINTENANCE_MODE=yes reports "maintenanceMode":false; DNSWATCHER_SEND_TEST_NOTIFICATION=yes sends no test notification.
The interval settings already stop startup on a bad value, naming the variable and the value (README, Configuration). These five should do the same.
Done when:
PORT must be a whole number from 1 to 65535, and DNSWATCHER_TLS_EXPIRY_WARNING a whole number of days, 1 or more. DNSWATCHER_DEBUG, DNSWATCHER_MAINTENANCE_MODE and DNSWATCHER_SEND_TEST_NOTIFICATION take a value Go's strconv.ParseBool accepts. Anything else stops startup with an error naming the variable and the value. Unset or empty still means the default.
Tests in internal/config cover a bad value and a good one for each.
The README's Configuration section says this, as its paragraph on the intervals does.
Severity: major
Model: opus-5-5
Found in the trial run for https://git.eeqj.de/sneak/dnswatcher/issues/260, on `next` at `e8b4006`.
`buildConfig` in `internal/config/config.go` reads `PORT` and `DNSWATCHER_TLS_EXPIRY_WARNING` with `viper.GetInt`, and `DNSWATCHER_DEBUG`, `DNSWATCHER_MAINTENANCE_MODE` and `DNSWATCHER_SEND_TEST_NOTIFICATION` with `viper.GetBool`. A value that does not parse becomes 0 or false, and dnswatcher starts with no error and nothing logged:
- `DNSWATCHER_TLS_EXPIRY_WARNING=abc`, or `-5`, gives a warning period of 0 days, so no expiry warning is ever sent: a certificate would be warned about only after it expired, and an expired one fails the TLS check instead.
- `PORT=notaport` starts the HTTP server on a random port (`"addr":":0"` in the log). The dashboard, the API and the image's `HEALTHCHECK` cannot reach it.
- `DNSWATCHER_MAINTENANCE_MODE=yes` reports `"maintenanceMode":false`; `DNSWATCHER_SEND_TEST_NOTIFICATION=yes` sends no test notification.
The interval settings already stop startup on a bad value, naming the variable and the value (README, Configuration). These five should do the same.
Done when:
- `PORT` must be a whole number from 1 to 65535, and `DNSWATCHER_TLS_EXPIRY_WARNING` a whole number of days, 1 or more. `DNSWATCHER_DEBUG`, `DNSWATCHER_MAINTENANCE_MODE` and `DNSWATCHER_SEND_TEST_NOTIFICATION` take a value Go's `strconv.ParseBool` accepts. Anything else stops startup with an error naming the variable and the value. Unset or empty still means the default.
- Tests in `internal/config` cover a bad value and a good one for each.
- The README's Configuration section says this, as its paragraph on the intervals does.
Severity: major
Model: opus-5-5
clawbot
added this to the 1.0 milestone 2026-10-13 12:50:07 +02:00
clawbot
self-assigned this 2026-10-13 12:50:07 +02:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Found in the trial run for #260, on
nextate8b4006.buildConfigininternal/config/config.goreadsPORTandDNSWATCHER_TLS_EXPIRY_WARNINGwithviper.GetInt, andDNSWATCHER_DEBUG,DNSWATCHER_MAINTENANCE_MODEandDNSWATCHER_SEND_TEST_NOTIFICATIONwithviper.GetBool. A value that does not parse becomes 0 or false, and dnswatcher starts with no error and nothing logged:DNSWATCHER_TLS_EXPIRY_WARNING=abc, or-5, gives a warning period of 0 days, so no expiry warning is ever sent: a certificate would be warned about only after it expired, and an expired one fails the TLS check instead.PORT=notaportstarts the HTTP server on a random port ("addr":":0"in the log). The dashboard, the API and the image'sHEALTHCHECKcannot reach it.DNSWATCHER_MAINTENANCE_MODE=yesreports"maintenanceMode":false;DNSWATCHER_SEND_TEST_NOTIFICATION=yessends no test notification.The interval settings already stop startup on a bad value, naming the variable and the value (README, Configuration). These five should do the same.
Done when:
PORTmust be a whole number from 1 to 65535, andDNSWATCHER_TLS_EXPIRY_WARNINGa whole number of days, 1 or more.DNSWATCHER_DEBUG,DNSWATCHER_MAINTENANCE_MODEandDNSWATCHER_SEND_TEST_NOTIFICATIONtake a value Go'sstrconv.ParseBoolaccepts. Anything else stops startup with an error naming the variable and the value. Unset or empty still means the default.internal/configcover a bad value and a good one for each.Severity: major
Model: opus-5-5