Skip to main content

dj-static-jl

This is a modification of the original dj-static by Kenneth Reitz (https://pypi.python.org/pypi/dj-static)

This is a simple Django middleware utility that allows you to properly serve static assets from production with a WSGI server like Gunicorn.

Django doesn’t recommend the production use of its static file server for a number of reasons. There exists, however, a lovely WSGI application aptly named Static.

It is suitable for the production use of static file serving, unlike Django.

Usage

Configure your static assets in settings.py:

STATIC_ROOT = 'staticfiles'
STATIC_URL = '/static/'

Then, update your wsgi.py file to use dj-static:

from django.core.wsgi import get_wsgi_application
from dj_static import Cling

application = Cling(get_wsgi_application())

or:

from django.core.wsgi import get_wsgi_application
from dj_static import Cling
import static

class BaseCling(static.Cling):
    ...

application = Cling(get_wsgi_application(), cling_class=BaseCling)

Metadata

Release files for dj-static-jl 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dj-static-jl 0.1.0
File Size Uploaded Provenance
dj-static-jl-0.1.0.tar.gz 3.5 kB Without provenance Details

Release files / dj-static-jl-0.1.0.tar.gz

Download URL dj-static-jl-0.1.0.tar.gz
Size 3.5 kB
Tags Source
SHA-256 checksum
How to use checksums
3647db41e03db6cd9f9f4f8c0e4df10bc42264a01f5345872046a383ff0de971
BLAKE2b-256 checksum
How to use checksums
f0dd57a7e86da477d8453f9019d1a87c027398f1b58168ff4e40777403225c22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for dj-static-jl 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page