summaryrefslogtreecommitdiff
path: root/src/core/namespace.h
diff options
context:
space:
mode:
authorMichal Sekletar <msekleta@redhat.com>2013-03-14 18:12:27 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-03-15 22:56:40 -0400
commitc17ec25e4d9bd6c8e8617416f813e25b2ebbafc5 (patch)
tree6a414a30460e6a362180a059bc93e88cea946916 /src/core/namespace.h
parent3b953d68c628c6ae70adba871719ac0f16083b51 (diff)
core: reuse the same /tmp, /var/tmp and inaccessible dir
All Execs within the service, will get mounted the same /tmp and /var/tmp directories, if service is configured with PrivateTmp=yes. Temporary directories are cleaned up by service itself in addition to systemd-tmpfiles. Directory which is mounted as inaccessible is created at runtime in /run/systemd.
Diffstat (limited to 'src/core/namespace.h')
-rw-r--r--src/core/namespace.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/core/namespace.h b/src/core/namespace.h
index 5d72ed91fb..7b886b8abf 100644
--- a/src/core/namespace.h
+++ b/src/core/namespace.h
@@ -23,9 +23,13 @@
#include <stdbool.h>
-int setup_namespace(
- char **writable,
- char **readable,
- char **inaccessible,
- bool private_tmp,
- unsigned long flags);
+typedef struct ExecContext ExecContext;
+
+int setup_tmpdirs(char **tmp_dir, char **var_tmp_dir);
+int setup_namespace(char **read_write_dirs,
+ char **read_only_dirs,
+ char **inaccessible_dirs,
+ char *tmp_dir,
+ char *var_tmp_dir,
+ bool private_tmp,
+ unsigned mount_flags);