summaryrefslogtreecommitdiff
path: root/src/nspawn
diff options
context:
space:
mode:
Diffstat (limited to 'src/nspawn')
-rw-r--r--src/nspawn/nspawn.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c
index 212f7223bb..501bccae87 100644
--- a/src/nspawn/nspawn.c
+++ b/src/nspawn/nspawn.c
@@ -89,6 +89,7 @@
#include "gpt.h"
#include "siphash24.h"
#include "copy.h"
+#include "base-filesystem.h"
#ifdef HAVE_SECCOMP
#include "seccomp-util.h"
@@ -3008,6 +3009,12 @@ int main(int argc, char *argv[]) {
srv_device, srv_device_rw) < 0)
goto child_fail;
+ r = base_filesystem_create(arg_directory);
+ if (r < 0) {
+ log_error("creating base filesystem failed: %s", strerror(-r));
+ goto child_fail;
+ }
+
/* Turn directory into bind mount */
if (mount(arg_directory, arg_directory, "bind", MS_BIND|MS_REC, NULL) < 0) {
log_error("Failed to make bind mount: %m");