Skip to content

Commit

Permalink
(fix): user creation for self-hosted clean installs (#54776)
Browse files Browse the repository at this point in the history
Tested locally, it works. Hacky, but it gets the job done
  • Loading branch information
hubertdeng123 authored Aug 15, 2023
1 parent a2aa289 commit 3c714c8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/sentry/receivers/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@
from sentry.models.user import User
from sentry.signals import post_upgrade
from sentry.silo import SiloMode
from sentry.utils.settings import is_self_hosted


def create_first_user(**kwargs):
if User.objects.filter(is_superuser=True).exists():
return

if not sys.stdin.isatty():
if not sys.stdin.isatty() and not is_self_hosted():
return

if not kwargs["interactive"]:
Expand Down

0 comments on commit 3c714c8

Please sign in to comment.