From 9f9117c3181c1212806a27625410df1e84efdbfb Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Sun, 9 Mar 2025 22:59:07 -0500 Subject: [PATCH] Ensure admin is default role (#17044) --- frigate/app.py | 1 + frigate/models.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/frigate/app.py b/frigate/app.py index cdb4877cc..a77533619 100644 --- a/frigate/app.py +++ b/frigate/app.py @@ -600,6 +600,7 @@ class FrigateApp: User.insert( { User.username: "admin", + User.role: "admin", User.password_hash: password_hash, User.notification_tokens: [], } diff --git a/frigate/models.py b/frigate/models.py index 26375432e..11b25b938 100644 --- a/frigate/models.py +++ b/frigate/models.py @@ -119,7 +119,7 @@ class User(Model): # type: ignore[misc] username = CharField(null=False, primary_key=True, max_length=30) role = CharField( max_length=20, - default="viewer", + default="admin", ) password_hash = CharField(null=False, max_length=120) notification_tokens = JSONField()