When moving your project to a production environment, you probably want to setup caching (e.g. memcache or redis)
Django-mub can take advantage of django’s caching abstractions.
MUB_MINIFY = Truein your settings (this is already done unless you have explicitly set it to False).
python manage.py mub_minifyto your build process (django-mub’s custom management command)
- (optional) if your cache is unstable, add the
mub_minifymanagement command to some sort of cron job on your server.
Following those steps will store the names of your CSS and JS minified files in the cache, so that the server doesn’t need to try to re-compile the files on each request.
This is a fairly important thing to configure, particularly for high-volume sites. The disk I/O is rough in a high-volume production environment.
If your cache should fail at some point though, django-mub will simply fall back to a state that doesn’t require a caching layer. In other words, your static files won’t break if your cache layer fails.