Skip to content

nanorepublica/django-prodserver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

django-prodserver

PyPI Status Python Version License

Read the documentation at https://django-prodserver.readthedocs.io/ Tests Codecov

pre-commit Black

Features

This package features 2 new management commands

  • manage.py devserver - this is a simple rename of runserver
  • manage.py prodserver - this will start your wsgi/asgi server

Includes in this package are configurations for gunicorn, waitress and uvicorn (wgsi & asgi)

Requirements

  • django-click
  • your wsgi/asgi server of choice

Installation

You can install django-prodserver via pip from PyPI:

$ pip install django_prodserver

Add the following settings:

INSTALLED_APPS += ["django_prodserver"]

PROD_SERVERS = {
    'web': {
        "BACKEND": "django_prodserver.backends.gunicorn.GunicornServer",
        "ARGS": [
            "--bind=0.0.0.0:8111"
            # other gunicorn commmand line args go here
        ]
    }
}

Then you will be able to use the management command like so:

$ python manage.py prodserver web

Usage

Please see the Command-line Reference for details.

Contributing

Contributions are very welcome. To learn more, see the Contributor Guide.

License

Distributed under the terms of the MIT license, django-prodserver is free and open source software.

Issues

If you encounter any problems, please file an issue along with a detailed description.

Credits

This project was generated from @OmenApps's Cookiecutter Django Package template.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published