mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-08-01 08:32:18 +03:00
Add basic config editor when Frigate can't startup (#18383)
* Start Frigate in safe mode when config does not validate * Add safe mode page that is just the config editor * Adjust Frigate config editor when in safe mode * Cleanup * Improve log message
This commit is contained in:
committed by
Blake Blackshear
parent
723553edb7
commit
cf1d50be30
+8
-1
@@ -93,7 +93,14 @@ def main() -> None:
|
||||
print("*************************************************************")
|
||||
print("*** End Config Validation Errors ***")
|
||||
print("*************************************************************")
|
||||
sys.exit(1)
|
||||
|
||||
# attempt to start Frigate in recovery mode
|
||||
try:
|
||||
config = FrigateConfig.load(install=True, safe_load=True)
|
||||
print("Starting Frigate in safe mode.")
|
||||
except ValidationError:
|
||||
print("Unable to start Frigate in safe mode.")
|
||||
sys.exit(1)
|
||||
if args.validate_config:
|
||||
print("*************************************************************")
|
||||
print("*** Your config file is valid. ***")
|
||||
|
||||
Reference in New Issue
Block a user