0

I've noticed that when i run python manage.py collectstatic --noinput users start seeing scrambled pages. After following on this, i found out that during the process i get 404 on css files, hence the scrambled view.

I've read the docs on Heroku regarding maintenance mode and deploying process, and nothing indicates that i need to turn maintenance mode on when i do a deploy with collectstatic.

The process of collecting static files is quite slow(~20 mins). I'm using django-pipeline to minify and combine the static files (with hashes),and then upload them to Amazon S3.

Is this a normal behaviour? Or am i doing something wrong?

Is there any way to deploy, with collectstatic, without taking the site down?

Neara
  • 3,693
  • 7
  • 29
  • 40

1 Answers1

0

If you're having issues with the speed. Perhaps you could just upload the static files using collect static locally (or on another server) instead of on Heroku, of course you'll have to set up a process for that, but at least you won't have to tie up an expensive server for 20 minutes just to upload files.

You could also use: https://github.com/antonagestam/collectfast which speeds up the collect process by using md5 hashes. This would really improve the speed since only the "newness" would get uploaded.

stormlifter
  • 3,781
  • 3
  • 17
  • 20