Dear Andrew, that is clear. Thank you very much for quick response. суббота, 13 мая 2017 г., 0:39:42 UTC+3 пользователь Andrew Godwin написал: > > Then I'm afraid you're stuck for now - you are welcome to open an issue > against the Channels project to fix it and even write a patch if you want, > but as DEBUG isn't turned on for production installs, it'll be considered a > little lower priority. > > Andrew > > On Fri, May 12, 2017 at 1:17 PM, Alexander Prokhorov <[email protected] > <javascript:>> wrote: > >> Yes, that is obvious, forgot to mention this. I would be happy to get rid >> of staticfiles completely, but several Django apps we use depend on it. >> Namely "debug_toolbar" and "django_rest_framework". I suppose staticfiles >> declares some keywords for templates those apps use. >> >> >> >> пятница, 12 мая 2017 г., 22:06:17 UTC+3 пользователь Andrew Godwin >> написал: >>> >>> Have you tried removing the staticfiles app from INSTALLED_APPS? I >>> believe that will disable it even with runworker. >>> >>> Andrew >>> >>> On Fri, May 12, 2017 at 11:14 AM, Alexander Prokhorov <[email protected]> >>> wrote: >>> >>>> Dear Colleagues, in particular Andrew ;) >>>> >>>> I have a problem with making Channels serve static files. The issue >>>> concerns running `./manage.py runworker` which (according to the Getting >>>> Started with Channels guide) serves static files if Django run in DEBUG >>>> mode. Actually, I would like to disable serving static files completely >>>> because I always use Whitenoise in both development mode and in >>>> production. >>>> Providing `--nostatic` to `runserver` command does the trick, but only if >>>> workers run in-process. >>>> In my setup I separate server from workers, so I run server as >>>> `./manage.py runserver --nostatic --noworker` and run workers separately >>>> with `./manage.py runworker --only-channels...`. Unfortunately in this >>>> case >>>> workers continue serving static files if they run in DEBUG mode, but the >>>> whole point of `--nostatic` is to disable serving static even in DEBUG >>>> mode >>>> (in production mode it is disabled by default AFAIR). >>>> >>>> Is there any workaround? >>>> >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "Django developers (Contributions to Django itself)" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to [email protected]. >>>> To post to this group, send email to [email protected]. >>>> Visit this group at https://groups.google.com/group/django-developers. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/django-developers/e6a3cbb8-363d-415b-be61-610d9cc50f58%40googlegroups.com >>>> >>>> <https://groups.google.com/d/msgid/django-developers/e6a3cbb8-363d-415b-be61-610d9cc50f58%40googlegroups.com?utm_medium=email&utm_source=footer> >>>> . >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >> You received this message because you are subscribed to the Google Groups >> "Django developers (Contributions to Django itself)" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> To post to this group, send email to [email protected] >> <javascript:>. >> Visit this group at https://groups.google.com/group/django-developers. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/django-developers/ac8eb115-71a6-4280-bec9-240f0df7e171%40googlegroups.com >> >> <https://groups.google.com/d/msgid/django-developers/ac8eb115-71a6-4280-bec9-240f0df7e171%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > >
-- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/a528e98e-94db-4e20-8634-effa2347bd2a%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
