Overview of WhiteNoise
mainWhiteNoise is a library for radically simplified static file serving for Python web applications. It allows your web app to serve its own static files, making it a self-contained unit that can be deployed anywhere (such as Heroku or OpenShift) without relying on external services like nginx or Amazon S3. It is designed to work with any WSGI-compatible application and includes special auto-configuration features for Django. It also handles best practices automatically, including:
- Serving compressed content (gzip and Brotli formats) while correctly handling
Accept-EncodingandVaryheaders. - Setting far-future cache headers on immutable content.
- Compatibility with CDNs for high-traffic performance.