summaryrefslogtreecommitdiff
path: root/execute.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-01-28 02:06:20 +0100
committerLennart Poettering <lennart@poettering.net>2010-01-28 02:06:20 +0100
commit071830ff32351c19343ff1f0343c13d5c2b69250 (patch)
tree9e564b64a8d80ee717b5d5859ac3d56ba350a087 /execute.h
parentce578209aa4e061aa38d3a4727612bb388307bf9 (diff)
implement proper logging for services
Diffstat (limited to 'execute.h')
-rw-r--r--execute.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/execute.h b/execute.h
index b7dbe68491..3283e1f815 100644
--- a/execute.h
+++ b/execute.h
@@ -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);