Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus <iMarkus@users.noreply.github.com>2017-12-15 07:25:40 +0300
committerMatthieu Aubry <mattab@users.noreply.github.com>2017-12-15 07:25:40 +0300
commite78d5c9bfdaaf0a1c58d2f24b2a79fc918947364 (patch)
tree0689a285ca587cf88a112c033db1bf99f6c1a7db
parentd647d5c99ea4cf46bfbb699ae67ae84ba0982af7 (diff)
Ability to customise the piwik/tmp directory path in config/config.ini.php file (#12189)
-rw-r--r--config/global.ini.php5
-rw-r--r--config/global.php7
2 files changed, 9 insertions, 3 deletions
diff --git a/config/global.ini.php b/config/global.ini.php
index 6aa9f65175..eae5a3a705 100644
--- a/config/global.ini.php
+++ b/config/global.ini.php
@@ -135,7 +135,6 @@ enabled = 0
disable_merged_assets = 0
[General]
-
; the following settings control whether Unique Visitors `nb_uniq_visitors` and Unique users `nb_users` will be processed for different period types.
; year and range periods are disabled by default, to ensure optimal performance for high traffic Piwik instances
; if you set it to 1 and want the Unique Visitors to be re-processed for reports in the past, drop all piwik_archive_* tables
@@ -573,6 +572,10 @@ enable_custom_logo_check = 1
; absolute path to the chroot environment. eg. '/path/to/piwik/chrooted/'
absolute_chroot_path =
+; The path (relative to the Piwik directory) in which Piwik temporary files are stored.
+; Defaults to ./tmp (the tmp/ folder inside the Piwik directory)
+tmp_path = "/tmp"
+
; In some rare cases it may be useful to explicitely tell Piwik not to use LOAD DATA INFILE
; This may for example be useful when doing Mysql AWS replication
enable_load_data_infile = 1
diff --git a/config/global.php b/config/global.php
index 00c2d116aa..f7ac26c544 100644
--- a/config/global.php
+++ b/config/global.php
@@ -4,6 +4,7 @@ use Interop\Container\ContainerInterface;
use Interop\Container\Exception\NotFoundException;
use Piwik\Cache\Eager;
use Piwik\SettingsServer;
+use Piwik\Config;
return array(
@@ -19,8 +20,10 @@ return array(
} else {
$instanceId = '';
}
-
- return $root . '/tmp' . $instanceId;
+
+ $tmp = Config::getInstance()->General['tmp_path'];
+
+ return $root . $tmp . $instanceId;
},
'path.cache' => DI\string('{path.tmp}/cache/tracker/'),