Skip to content
Snippets Groups Projects
Unverified Commit 6a3f169c authored by Tim van Dijen's avatar Tim van Dijen Committed by GitHub
Browse files

Add cachedir-setting and use it for Symfony cache (#1932)


* Add cachedir-setting and use it for Symfony cache

* s/Symfony/SimpleSAMLphp

Co-authored-by: default avatarThijs Kinkhorst <thijs@kinkhorst.com>

* Remove tempdir

---------

Co-authored-by: default avatarThijs Kinkhorst <thijs@kinkhorst.com>
parent 091a30a4
No related branches found
No related tags found
No related merge requests found
......@@ -58,17 +58,17 @@ $config = [
/*
* The following settings are *filesystem paths* which define where
* SimpleSAMLphp can find or write the following things:
* - 'cachedir': Where SimpleSAMLphp can write its cache.
* - 'loggingdir': Where to write logs. MUST be set to NULL when using a logging
* handler other than `file`.
* - 'datadir': Storage of general data.
* - 'tempdir': Saving temporary files. SimpleSAMLphp will attempt to create
* this directory if it doesn't exist.
* When specified as a relative path, this is relative to the SimpleSAMLphp
* root directory.
*/
'cachedir' => '/var/cache/simplesamlphp',
//'loggingdir' => '/var/log/',
//'datadir' => '/var/data/',
'tempdir' => '/tmp/simplesaml',
/*
* Certificate and key material can be loaded from different possible
......
......@@ -51,8 +51,7 @@ class Kernel extends BaseKernel
public function getCacheDir(): string
{
$configuration = Configuration::getInstance();
$cachePath = $configuration->getString('tempdir') . DIRECTORY_SEPARATOR
. 'cache' . DIRECTORY_SEPARATOR . $this->module;
$cachePath = $configuration->getString('cachedir') . DIRECTORY_SEPARATOR . $this->module;
$sysUtils = new System();
if ($sysUtils->isAbsolutePath($cachePath)) {
......
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