mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-15 09:24:52 +03:00
Add Azure Storage as an option to serve static and media files
This commit is contained in:
parent
50f4c4ec56
commit
9b2a3636ab
|
@ -22,4 +22,15 @@ class StaticRootGoogleCloudStorage(GoogleCloudStorage):
|
|||
class MediaRootGoogleCloudStorage(GoogleCloudStorage):
|
||||
location = "media"
|
||||
file_overwrite = False
|
||||
{%- elif cookiecutter.cloud_provider == 'Azure' -%}
|
||||
from storages.backends.azure_storage import AzureStorage
|
||||
|
||||
|
||||
class StaticRootAzureStorage(AzureStorage):
|
||||
location = "static"
|
||||
|
||||
|
||||
class MediaRootAzureStorage(AzureStorage):
|
||||
location = "media"
|
||||
file_overwrite = False
|
||||
{%- endif %}
|
||||
|
|
Loading…
Reference in New Issue
Block a user