Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Django contrib admin default admin and password

Tags:

django

This may be a silly question. I start a new Django project as Document says, which only included an admin page. I start the server and use a web browser accessing the page. What can I enter in the username and password? Is their any place for me to config the default admin account?

like image 768
Wason Avatar asked Sep 26 '16 06:09

Wason


People also ask

Where is Django contrib admin templates admin?

The default templates used by the Django admin are located under the /django/contrib/admin/templates/ directory of your Django installation inside your operating system's or virtual env Python environment (e.g. <virtual_env_directory>/lib/python3. 5/site-packages/django/contrib/admin/templates/ ).

What is Django contrib admin?

contrib. admin.sites register Example Code. The Django admin is an automatically-generated user interface for Django models. The register function is used to add models to the Django admin so that data for those models can be created, deleted, updated and queried through the user interface.

What are the default password validators in Django?

By default, Django uses the PBKDF2 algorithm with a SHA256 hash, a password stretching mechanism recommended by NIST.


1 Answers

You can config using following command line in shell

python manage.py createsuperuser 

Basically you're creating superuser who can access the django admin panel.

like image 159
sriramganesh Avatar answered Sep 28 '22 10:09

sriramganesh