diff options
author | Lennart Poettering <lennart@poettering.net> | 2010-01-28 02:06:20 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2010-01-28 02:06:20 +0100 |
commit | 071830ff32351c19343ff1f0343c13d5c2b69250 (patch) | |
tree | 9e564b64a8d80ee717b5d5859ac3d56ba350a087 /execute.h | |
parent | ce578209aa4e061aa38d3a4727612bb388307bf9 (diff) |
implement proper logging for services
Diffstat (limited to 'execute.h')
-rw-r--r-- | execute.h | 20 |
1 files changed, 18 insertions, 2 deletions
@@ -16,6 +16,16 @@ typedef struct ExecContext ExecContext; #include "list.h" #include "util.h" +/* Abstract namespace! */ +#define LOGGER_SOCKET "/systemd/logger" + +typedef enum ExecOutput { + EXEC_CONSOLE, + EXEC_NULL, + EXEC_SYSLOG, + EXEC_KERNEL +} ExecOutput; + struct ExecStatus { pid_t pid; usec_t timestamp; @@ -33,11 +43,16 @@ struct ExecCommand { struct ExecContext { char **environment; mode_t umask; - struct rlimit *rlimit[RLIMIT_NLIMITS]; + struct rlimit *rlimit[RLIMIT_NLIMITS]; /* FIXME: load-fragment parser missing */ int oom_adjust; int nice; char *directory; + ExecOutput output; + int syslog_priority; + char *syslog_identifier; + + /* FIXME: all privs related settings need parser and enforcer */ cap_t capabilities; bool capabilities_set:1; @@ -72,7 +87,8 @@ typedef enum ExitStatus { EXIT_MEMORY, EXIT_LIMITS, EXIT_OOM_ADJUST, - EXIT_SIGNAL_MASK + EXIT_SIGNAL_MASK, + EXIT_OUTPUT } ExitStatus; int exec_spawn(const ExecCommand *command, const ExecContext *context, int *fds, unsigned n_fds, pid_t *ret); |