summaryrefslogtreecommitdiffstats
path: root/.config/s3.config.php
diff options
context:
space:
mode:
authorjohackim <contact@johackim.com>2021-02-22 18:06:40 +0100
committerGitHub <noreply@github.com>2021-02-22 17:06:40 +0000
commit94e751cd97d7cfb05086edd3aeeb23647c7f9ca1 (patch)
tree90acc24e6449fa40295fb885f1949018e6fb922b /.config/s3.config.php
parent8b9ca85ac55aecd83177817bb077ee7ba238132b (diff)
Add objectPrefix et autocreate environment variables (#1389)
Signed-off-by: johackim <contact@johackim.com>
Diffstat (limited to '.config/s3.config.php')
-rw-r--r--.config/s3.config.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/.config/s3.config.php b/.config/s3.config.php
index 6376d8f6..9a19e96f 100644
--- a/.config/s3.config.php
+++ b/.config/s3.config.php
@@ -2,6 +2,7 @@
if (getenv('OBJECTSTORE_S3_BUCKET')) {
$use_ssl = getenv('OBJECTSTORE_S3_SSL');
$use_path = getenv('OBJECTSTORE_S3_USEPATH_STYLE');
+ $autocreate = getenv('OBJECTSTORE_S3_AUTOCREATE');
$CONFIG = array(
'objectstore' => array(
'class' => '\OC\Files\ObjectStore\S3',
@@ -12,6 +13,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
'region' => getenv('OBJECTSTORE_S3_REGION') ?: '',
'hostname' => getenv('OBJECTSTORE_S3_HOST') ?: '',
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
+ 'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
+ 'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
// required for some non Amazon S3 implementations
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false'