summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-11-18 00:42:35 +0100
committerLennart Poettering <lennart@poettering.net>2010-11-18 00:42:35 +0100
commit06d4c99ab3d479c1a7c087a87e82fe01626128f6 (patch)
treea0216fb2aaf68604a1c8198d0fdee742f43abaff /src/main.c
parent7838dc3ae1297d37c2a75a48f429bb415c1eed22 (diff)
manager: make list of default controllers configurable
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 4bdc6763fa..99e277c67b 100644
--- a/src/main.c
+++ b/src/main.c
@@ -49,6 +49,7 @@
#include "missing.h"
#include "label.h"
#include "build.h"
+#include "strv.h"
static enum {
ACTION_RUN,
@@ -72,6 +73,7 @@ static bool arg_sysv_console = true;
static bool arg_mount_auto = true;
static bool arg_swap_auto = true;
static char *arg_console = NULL;
+static char **arg_default_controllers = NULL;
static FILE* serialization = NULL;
@@ -502,6 +504,7 @@ static int parse_config_file(void) {
{ "CPUAffinity", config_parse_cpu_affinity, NULL, "Manager" },
{ "MountAuto", config_parse_bool, &arg_mount_auto, "Manager" },
{ "SwapAuto", config_parse_bool, &arg_swap_auto, "Manager" },
+ { "DefaultControllers", config_parse_strv, &arg_default_controllers, "Manager" },
{ NULL, NULL, NULL, NULL }
};
@@ -1089,6 +1092,9 @@ int main(int argc, char *argv[]) {
if (arg_console)
manager_set_console(m, arg_console);
+ if (arg_default_controllers)
+ manager_set_default_controllers(m, arg_default_controllers);
+
if ((r = manager_startup(m, serialization, fds)) < 0)
log_error("Failed to fully start up daemon: %s", strerror(-r));
@@ -1211,6 +1217,7 @@ finish:
free(arg_default_unit);
free(arg_console);
+ strv_free(arg_default_controllers);
dbus_shutdown();