aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--python/sandcrawler/minio.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/python/sandcrawler/minio.py b/python/sandcrawler/minio.py
index 25518f4..41dd29a 100644
--- a/python/sandcrawler/minio.py
+++ b/python/sandcrawler/minio.py
@@ -63,11 +63,15 @@ class SandcrawlerMinioClient(object):
if not bucket:
bucket = self.default_bucket
assert bucket
+ content_type = "application/octet-stream"
+ if extension.endswith('.xml'):
+ content_type = "application/xml"
self.mc.put_object(
bucket,
obj_path,
io.BytesIO(blob),
len(blob),
+ content_type=content_type,
)
return (bucket, obj_path)