createadmin


Namecreateadmin JSON
Version 1.0 PyPI version JSON
download
home_pagehttps://github.com/xB0t/createadmin
SummaryCreate Default Admin Credentials in Django Admin.
upload_time2023-12-19 12:35:20
maintainerxB0t
docs_urlNone
authorxB0t
requires_python
licenseMIT
keywords django django_admin django_admin_default_credentials django-admin-custom-credentials devops deployment
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            createadmin
==================

Create Django Admin Default Credentials
----------------------------------------

The `createadmin` package provides a Django management command, `createadmin`, that facilitates the creation of superuser default login credentials for the Django Admin Interface. This command is useful for setting up initial access to the admin interface during project development, packaging & deployment.

Installation
------------

To install the package, use the following pip command:

.. code-block:: bash

    pip install createadmin

After installation, add `'createadmin'` to the `INSTALLED_APPS` list in your project's `settings.py` file:

.. code-block:: python

    INSTALLED_APPS = [
        # ...
        'createadmin',
        # ...
    ]

Usage
-----

### Default Credentials

To create a superuser with the default credentials (username: admin, password: admin, email: admin@example.com), run the following command in the terminal:

.. code-block:: bash

    python manage.py createadmin

### Custom Credentials

You can also create a superuser with custom credentials by adding a dictionary block to your project's `settings.py` file:

.. code-block:: python

    # settings.py

    CREATE_ADMIN = {
        'username': 'your_custom_username',
        'password': 'your_custom_password',
        'email': 'your_custom_email@example.com',
    }

Then, run the following command in the terminal:

.. code-block:: bash

    python manage.py createadmin

**Note:** Ensure that the `'createadmin'` app is included in your `INSTALLED_APPS` list before running the command.

Example
-------

Here's an example of using custom credentials in the `settings.py` file:

.. code-block:: python

    # settings.py

    INSTALLED_APPS = [
        # ...
        'createadmin',
        # ...
    ]

    CREATE_ADMIN = {
        'username': 'yash',
        'password': 'yash',
        'email': 'ychaudhari124@gmail.com',
    }

Run the following command in the terminal:

.. code-block:: bash

    python manage.py createadmin

This will create a superuser with the specified custom credentials.

**Note:** It is recommended to change the default or custom credentials once the initial setup is complete for security reasons.

---

*This package simplifies the process of creating Django Admin default credentials, making it more efficient for project setup, development, packaging & deployment.*

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/xB0t/createadmin",
    "name": "createadmin",
    "maintainer": "xB0t",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "ychaudhari124@gmail.com",
    "keywords": "django django_admin django_admin_default_credentials django-admin-custom-credentials devops deployment",
    "author": "xB0t",
    "author_email": "ychaudhari124@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/d1/ec/e28ebc47198c6130e34611e67de7a323e745773ac419420481572fad6b79/createadmin-1.0.tar.gz",
    "platform": null,
    "description": "createadmin\r\n==================\r\n\r\nCreate Django Admin Default Credentials\r\n----------------------------------------\r\n\r\nThe `createadmin` package provides a Django management command, `createadmin`, that facilitates the creation of superuser default login credentials for the Django Admin Interface. This command is useful for setting up initial access to the admin interface during project development, packaging & deployment.\r\n\r\nInstallation\r\n------------\r\n\r\nTo install the package, use the following pip command:\r\n\r\n.. code-block:: bash\r\n\r\n    pip install createadmin\r\n\r\nAfter installation, add `'createadmin'` to the `INSTALLED_APPS` list in your project's `settings.py` file:\r\n\r\n.. code-block:: python\r\n\r\n    INSTALLED_APPS = [\r\n        # ...\r\n        'createadmin',\r\n        # ...\r\n    ]\r\n\r\nUsage\r\n-----\r\n\r\n### Default Credentials\r\n\r\nTo create a superuser with the default credentials (username: admin, password: admin, email: admin@example.com), run the following command in the terminal:\r\n\r\n.. code-block:: bash\r\n\r\n    python manage.py createadmin\r\n\r\n### Custom Credentials\r\n\r\nYou can also create a superuser with custom credentials by adding a dictionary block to your project's `settings.py` file:\r\n\r\n.. code-block:: python\r\n\r\n    # settings.py\r\n\r\n    CREATE_ADMIN = {\r\n        'username': 'your_custom_username',\r\n        'password': 'your_custom_password',\r\n        'email': 'your_custom_email@example.com',\r\n    }\r\n\r\nThen, run the following command in the terminal:\r\n\r\n.. code-block:: bash\r\n\r\n    python manage.py createadmin\r\n\r\n**Note:** Ensure that the `'createadmin'` app is included in your `INSTALLED_APPS` list before running the command.\r\n\r\nExample\r\n-------\r\n\r\nHere's an example of using custom credentials in the `settings.py` file:\r\n\r\n.. code-block:: python\r\n\r\n    # settings.py\r\n\r\n    INSTALLED_APPS = [\r\n        # ...\r\n        'createadmin',\r\n        # ...\r\n    ]\r\n\r\n    CREATE_ADMIN = {\r\n        'username': 'yash',\r\n        'password': 'yash',\r\n        'email': 'ychaudhari124@gmail.com',\r\n    }\r\n\r\nRun the following command in the terminal:\r\n\r\n.. code-block:: bash\r\n\r\n    python manage.py createadmin\r\n\r\nThis will create a superuser with the specified custom credentials.\r\n\r\n**Note:** It is recommended to change the default or custom credentials once the initial setup is complete for security reasons.\r\n\r\n---\r\n\r\n*This package simplifies the process of creating Django Admin default credentials, making it more efficient for project setup, development, packaging & deployment.*\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Create Default Admin Credentials in Django Admin.",
    "version": "1.0",
    "project_urls": {
        "Homepage": "https://github.com/xB0t/createadmin"
    },
    "split_keywords": [
        "django",
        "django_admin",
        "django_admin_default_credentials",
        "django-admin-custom-credentials",
        "devops",
        "deployment"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0b3fd19eac1380e2e7091f5106f4926deb96dc3eaf90d6c5927868863c980fc6",
                "md5": "9bd6eaf72661cec9535c661d7c49151f",
                "sha256": "a83e034a97e87179c859418ce6607c3be0b2317afc0dbbeb92f18577c04bf76b"
            },
            "downloads": -1,
            "filename": "createadmin-1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "9bd6eaf72661cec9535c661d7c49151f",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 4180,
            "upload_time": "2023-12-19T12:35:16",
            "upload_time_iso_8601": "2023-12-19T12:35:16.065582Z",
            "url": "https://files.pythonhosted.org/packages/0b/3f/d19eac1380e2e7091f5106f4926deb96dc3eaf90d6c5927868863c980fc6/createadmin-1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d1ece28ebc47198c6130e34611e67de7a323e745773ac419420481572fad6b79",
                "md5": "0967552033ed26b4a84975216b8962e0",
                "sha256": "f6519531ab9d6c80f89d41d2f12a26550358e92a63916636ceb20b866745c672"
            },
            "downloads": -1,
            "filename": "createadmin-1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "0967552033ed26b4a84975216b8962e0",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3629,
            "upload_time": "2023-12-19T12:35:20",
            "upload_time_iso_8601": "2023-12-19T12:35:20.814591Z",
            "url": "https://files.pythonhosted.org/packages/d1/ec/e28ebc47198c6130e34611e67de7a323e745773ac419420481572fad6b79/createadmin-1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-12-19 12:35:20",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "xB0t",
    "github_project": "createadmin",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "createadmin"
}
        
Elapsed time: 0.16744s