summaryrefslogtreecommitdiffstats
path: root/modules-available/runmode/inc/runmode.inc.php
diff options
context:
space:
mode:
authorSimon Rettberg2017-07-12 18:39:21 +0200
committerSimon Rettberg2017-07-12 18:39:21 +0200
commit6b5d3a94ed1b62728957b04b36a08327837b0b5f (patch)
treec3cf440c5ca2a6a34b74d08d5a571bc1312aa2e2 /modules-available/runmode/inc/runmode.inc.php
parent[baseconfig_partitions_cdn] Fix warning (diff)
downloadslx-admin-6b5d3a94ed1b62728957b04b36a08327837b0b5f.tar.gz
slx-admin-6b5d3a94ed1b62728957b04b36a08327837b0b5f.tar.xz
slx-admin-6b5d3a94ed1b62728957b04b36a08327837b0b5f.zip
[runmode] Tweaks, support NO_CONFIG and systemd target
Diffstat (limited to 'modules-available/runmode/inc/runmode.inc.php')
-rw-r--r--modules-available/runmode/inc/runmode.inc.php14
1 files changed, 12 insertions, 2 deletions
diff --git a/modules-available/runmode/inc/runmode.inc.php b/modules-available/runmode/inc/runmode.inc.php
index 5b59f1c1..916866f1 100644
--- a/modules-available/runmode/inc/runmode.inc.php
+++ b/modules-available/runmode/inc/runmode.inc.php
@@ -11,7 +11,7 @@ class RunMode
* @param string $module name of module
* @return RunModeModuleConfig|false
*/
- private static function getModuleConfig($module)
+ public static function getModuleConfig($module)
{
if (isset(self::$moduleConfigs[$module]))
return self::$moduleConfigs[$module];
@@ -155,9 +155,17 @@ class RunModeModuleConfig
*/
public $getModeName = false;
/**
+ * @var string Name of function that is called to add additional config entries
+ */
+ public $configHook = false;
+ /**
* @var bool Consider this a normal client that should e.g. be shown in client statistics by default
*/
public $isClient = false;
+ /**
+ * @var bool If true, config.tgz should not be downloaded by the client
+ */
+ public $noSysconfig = false;
public function __construct($file)
{
@@ -168,7 +176,9 @@ class RunModeModuleConfig
$this->loadType($data, 'systemdDisableTargets', 'array');
$this->loadType($data, 'systemdEnableTargets', 'array');
$this->loadType($data, 'getModeName', 'string');
- $this->loadType($data, 'isClient', 'string');
+ $this->loadType($data, 'configHook', 'string');
+ $this->loadType($data, 'isClient', 'boolean');
+ $this->loadType($data, 'noSysconfig', 'boolean');
}
private function loadType($data, $key, $type)