Python Forum

Full Version: How do I change the location of the _ versions directory?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
(Sorry for google translator)
When working together Django + TinyMCE + django-filebrowser + grappelli +... image thumbnails are created in the _versions directory at the root of the project. Is it possible (and necessary?) To change the location of this directory? I thought by defining FILEBROWSER_DIRECTORY = 'media/uploads/' and thumbnails would be there. How is this, in the future, prescribed in nginx? Separately static, separately media and more separately _ versions is something?

PS/according to one of the recommendations, I tried to determine MEDIA_URL = 'media/', thinking that miniatures would be created there, but this only led to the fact that in all links there was an extra leading media: http://192.168.100.19:8000/media/_versions...i etc.

Added later
The answer to my question was found.

Quote:We do recommend the following structure for media files:

└── media # site.storage.location (e.g. MEDIA_ROOT)
----── media/_versions # VERSIONS_BASEDIR (outside of site.directory)
----── media/uploads # site.directory

Warning

From version 3.7, defining a VERSIONS_BASEDIR outside of site.directory is mandatory.

Did I understand correctly that this catalog really should be at the root of the project? And how does it appear in nginx?
Thank`s for the "large number of answers." The answer was found, the question was closed.