From 521b287b134691ddb50efc936b4e483351dc7b12 Mon Sep 17 00:00:00 2001 From: Charles Date: Mon, 15 Jun 2015 09:17:59 +0000 Subject: [PATCH] Add extra_dir options for S3/Swift ObjectStore. --- config/object_store_conf.xml.sample | 12 ++++++++---- lib/galaxy/objectstore/s3.py | 8 ++++++++ 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/config/object_store_conf.xml.sample b/config/object_store_conf.xml.sample index 51e1a1529d7..b373e7b5b49 100644 --- a/config/object_store_conf.xml.sample +++ b/config/object_store_conf.xml.sample @@ -23,9 +23,11 @@ @@ -34,7 +36,9 @@ - + + + --> diff --git a/lib/galaxy/objectstore/s3.py b/lib/galaxy/objectstore/s3.py index 361c40a915a..a474fba3b0b 100644 --- a/lib/galaxy/objectstore/s3.py +++ b/lib/galaxy/objectstore/s3.py @@ -92,6 +92,14 @@ class S3ObjectStore(ObjectStore): self.conn_path = cn_xml.get('conn_path', '/') c_xml = config_xml.findall('cache')[0] self.cache_size = float(c_xml.get('size', -1)) + self.staging_path = c_xml.get('path', self.config.object_store_cache_path) + + for d_xml in config_xml.findall('extra_dir'): + self.extra_dirs[d_xml.get('type')] = d_xml.get('path') + + log.debug("Object cache dir: %s", self.staging_path) + log.debug(" job work dir: %s", self.extra_dirs['job_work']) + # for multipart upload self.s3server = {'access_key': self.access_key, 'secret_key': self.secret_key,