File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
root/etc/s6-overlay/s6-rc.d/init-netbox-config Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ mv /defaults/uwsgi.ini /app/netbox/netbox/uwsgi.ini > /dev/null 2>&1
5353if [[ ! -e "/app/netbox/netbox/project-static/docs/index.html" ]]; then
5454 cd /app/netbox || exit 1
5555 echo "Building local documentation"
56- mkdocs build
56+ mkdocs build -q
5757 cd /app/netbox/netbox || exit 1
5858fi
5959
@@ -66,13 +66,13 @@ s6-setuidgid abc python3 ./manage.py migrate
6666
6767if [[ -n "$SUPERUSER_EMAIL" ]] && [[ -n "$SUPERUSER_PASSWORD" ]]; then
6868cat << EOF | s6-setuidgid abc python3 /app/netbox/netbox/manage.py shell
69- from django.contrib.auth. models import User;
69+ from users. models import Token, User;
7070
7171username = 'admin';
7272password = '$SUPERUSER_PASSWORD';
7373email = '$SUPERUSER_EMAIL';
7474
75- if User.objects.filter(username=username).count()==0 :
75+ if not User.objects.filter(username='admin') :
7676 User.objects.create_superuser(username, email, password);
7777 print('Superuser created.');
7878else:
You can’t perform that action at this time.
0 commit comments