Resources: Support type 'ini' yet only in the resources.ini
Configuring the resource type 'ini' via the web interface is not yet possible.
This commit is contained in:
parent
cee261bf7e
commit
79ade944de
|
@ -4,8 +4,9 @@
|
||||||
|
|
||||||
namespace Icinga\Data;
|
namespace Icinga\Data;
|
||||||
|
|
||||||
use Icinga\Exception\ProgrammingError;
|
|
||||||
use Zend_Config;
|
use Zend_Config;
|
||||||
|
use Icinga\Application\Config;
|
||||||
|
use Icinga\Exception\ProgrammingError;
|
||||||
use Icinga\Util\ConfigAwareFactory;
|
use Icinga\Util\ConfigAwareFactory;
|
||||||
use Icinga\Exception\ConfigurationError;
|
use Icinga\Exception\ConfigurationError;
|
||||||
use Icinga\Data\Db\DbConnection;
|
use Icinga\Data\Db\DbConnection;
|
||||||
|
@ -120,6 +121,9 @@ class ResourceFactory implements ConfigAwareFactory
|
||||||
case 'file':
|
case 'file':
|
||||||
$resource = new FileReader($config);
|
$resource = new FileReader($config);
|
||||||
break;
|
break;
|
||||||
|
case 'ini':
|
||||||
|
$resource = Config::fromIni($config->ini);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
throw new ConfigurationError(
|
throw new ConfigurationError(
|
||||||
'Unsupported resource type "%s"',
|
'Unsupported resource type "%s"',
|
||||||
|
|
Loading…
Reference in New Issue