Skip to content
Snippets Groups Projects
Commit 18400d54 authored by Jenkins for Software Heritage's avatar Jenkins for Software Heritage
Browse files

Update upstream source from tag 'debian/upstream/1.4.2'

Update to upstream version '1.4.2'
with Debian dir 2b4aef9f7ac345385fda3320ce6b248a5c9e3950
parents 861f553e 0d347d14
No related branches found
No related tags found
No related merge requests found
Metadata-Version: 2.1
Name: swh.deposit
Version: 1.4.1
Version: 1.4.2
Summary: Software Heritage Deposit Server
Home-page: https://forge.softwareheritage.org/source/swh-deposit/
Author: Software Heritage developers
......
Metadata-Version: 2.1
Name: swh.deposit
Version: 1.4.1
Version: 1.4.2
Summary: Software Heritage Deposit Server
Home-page: https://forge.softwareheritage.org/source/swh-deposit/
Author: Software Heritage developers
......
......@@ -123,15 +123,27 @@ if cfg_azure:
f"Production: invalid configuration; missing {key} config entry."
)
# Default options
options = dict(
azure_container=cfg_azure["container_name"],
connection_string=cfg_azure["connection_string"],
)
# Which may be enhanced with some extra options, lookup "object_parameters" in
# https://django-storages.readthedocs.io/en/latest/backends/azure.html
object_parameters = {}
for optional_config_key in ["content_type", "content_disposition"]:
if optional_config_key in cfg_azure:
object_parameters[optional_config_key] = cfg_azure[optional_config_key]
options.update(dict(object_parameters=object_parameters))
STORAGES = {
"staticfiles": {
"BACKEND": "django.contrib.staticfiles.storage.StaticFilesStorage"
},
"default": {
"BACKEND": "storages.backends.azure_storage.AzureStorage",
"OPTIONS": {
"azure_container": cfg_azure["container_name"],
"connection_string": cfg_azure["connection_string"],
},
"OPTIONS": options,
},
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment