From 4f91af0ce9b9913d702941f19eb1e1c4ae39866d Mon Sep 17 00:00:00 2001 From: Nick Sweeting Date: Fri, 23 Apr 2021 15:50:33 -0400 Subject: [PATCH] TODO create admin user from env vars --- archivebox/main.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/archivebox/main.py b/archivebox/main.py index 0107bac0..373c8040 100644 --- a/archivebox/main.py +++ b/archivebox/main.py @@ -406,6 +406,11 @@ def init(force: bool=False, quick: bool=False, setup: bool=False, out_dir: Path= if existing_index: print('{green}[√] Done. Verified and updated the existing ArchiveBox collection.{reset}'.format(**ANSI)) else: + # TODO: allow creating new supersuer via env vars on first init + # if config.HTTP_USER and config.HTTP_PASS: + # from django.contrib.auth.models import User + # User.objects.create_superuser(HTTP_USER, '', HTTP_PASS) + print('{green}[√] Done. A new ArchiveBox collection was initialized ({} links).{reset}'.format(len(all_links) + len(pending_links), **ANSI)) json_index = out_dir / JSON_INDEX_FILENAME