summaryrefslogtreecommitdiff
path: root/src/service.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-05-19 04:28:25 +0200
committerLennart Poettering <lennart@poettering.net>2010-05-19 04:28:25 +0200
commit15ca554ba3a40e6840c6d6095ec90cf448720454 (patch)
tree0b0a7884d483775865d9a7c9b8a49ec3284da7d2 /src/service.c
parent56d748b47e289fc0fcdf7925df1580afbc2d220a (diff)
service: by default send service output to syslog, except for SysV services which should go to the console
Diffstat (limited to 'src/service.c')
-rw-r--r--src/service.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/service.c b/src/service.c
index 2515cd305f..0615b51490 100644
--- a/src/service.c
+++ b/src/service.c
@@ -632,6 +632,11 @@ static int service_load_sysv_path(Service *s, const char *path) {
s->valid_no_process = true;
s->kill_mode = KILL_PROCESS_GROUP;
+ /* For SysV services log output should go to the console */
+ s->exec_context.std_input = EXEC_INPUT_NULL;
+ s->exec_context.std_output = EXEC_OUTPUT_TTY;
+ s->exec_context.std_error = EXEC_OUTPUT_TTY;
+
u->meta.load_state = UNIT_LOADED;
r = 0;