Lines Matching defs:directory
189 " -D --directory=PATH Root directory for the container\n"
190 " --template=PATH Initialize root directory from template directory,\n"
192 " -x --ephemeral Run container with snapshot of root directory, and\n"
197 " --chdir=PATH Set working directory in the container\n"
239 " --read-only Mount the root directory read-only\n"
241 " Bind mount a file or directory from the host into\n"
245 " --tmpfs=PATH:[OPTIONS] Mount an empty tmpfs to the specified directory\n"
289 return log_error_errno(r, "Failed to generate work directory from %s: %m", m->source);
356 { "directory", required_argument, NULL, 'D' },
680 * second one the upper directory. And
874 log_error("Working directory %s is not an absolute path.", optarg);
906 log_error("--directory= and --image= may not be combined.");
916 log_error("--template= needs --directory= or --machine=.");
1187 return log_error_errno(r, "Failed to create /dev/net directory: %m");
1369 static int setup_journal(const char *directory) {
1386 etc_machine_id = prefix_roota(directory, "/etc/machine-id");
1415 r = userns_mkdir(directory, "/var", 0755, 0, 0);
1419 r = userns_mkdir(directory, "/var/log", 0755, 0, 0);
1423 r = userns_mkdir(directory, "/var/log/journal", 0755, 0, 0);
1428 q = prefix_roota(directory, p);
1452 r = userns_mkdir(directory, p, 0755, 0, 0);
1454 log_warning_errno(r, "Failed to create directory %s: %m", q);
1466 log_error("%s already exists and is neither a symlink nor a directory", p);
1484 r = userns_mkdir(directory, p, 0755, 0, 0);
1486 log_warning_errno(r, "Failed to create directory %s: %m", q);
1508 r = userns_mkdir(directory, p, 0755, 0, 0);
2134 static int mount_device(const char *what, const char *where, const char *directory, bool rw) {
2146 if (directory)
2147 p = strjoina(where, directory);
2208 return log_error_errno(r, "Failed to mount root directory: %m");
2214 return log_error_errno(r, "Failed to mount home directory: %m");
2220 return log_error_errno(r, "Failed to mount server data directory: %m");
2363 return log_error_errno(r, "Invalid image directory: %m");
2410 static int determine_uid_shift(const char *directory) {
2421 r = stat(directory, &st);
2423 return log_error_errno(errno, "Failed to determine UID base of %s: %m", directory);
2428 log_error("UID and GID base of %s don't match.", directory);
2446 const char *directory,
2471 assert(directory);
2601 return log_error_errno(errno, "Failed to change to specified working directory %s: %m", arg_chdir);
2658 const char *directory,
2676 assert(directory);
2716 r = mount_devices(directory,
2723 r = determine_uid_shift(directory);
2737 /* Turn directory into bind mount */
2738 if (mount(directory, directory, NULL, MS_BIND|MS_REC, NULL) < 0)
2741 r = setup_volatile(directory, arg_volatile_mode, arg_userns, arg_uid_shift, arg_uid_range, arg_selinux_context);
2745 r = setup_volatile_state(directory, arg_volatile_mode, arg_userns, arg_uid_shift, arg_uid_range, arg_selinux_context);
2749 r = base_filesystem_create(directory, arg_uid_shift, (gid_t) arg_uid_shift);
2754 r = bind_remount_recursive(directory, true);
2759 r = mount_all(directory, arg_userns, false, arg_private_network, arg_uid_shift, arg_uid_range, arg_selinux_apifs_context);
2763 r = copy_devnodes(directory);
2767 dev_setup(directory, arg_uid_shift, arg_uid_shift);
2769 r = setup_pts(directory);
2773 r = setup_propagate(directory);
2777 r = setup_dev_console(directory, console);
2785 r = setup_timezone(directory);
2789 r = setup_resolv_conf(directory);
2793 r = setup_journal(directory);
2797 r = mount_custom(directory, arg_custom_mounts, arg_n_custom_mounts, arg_userns, arg_uid_shift, arg_uid_range, arg_selinux_apifs_context);
2801 r = mount_cgroups(directory, arg_unified_cgroup_hierarchy, arg_userns, arg_uid_shift, arg_uid_range, arg_selinux_apifs_context);
2805 r = mount_move_root(directory);
2807 return log_error_errno(r, "Failed to move root directory: %m");
2824 r = inner_child(barrier, directory, secondary, kmsg_socket, rtnl_socket, fds);
3137 log_error("Spawning container on root directory is not supported. Consider using --ephemeral.");
3150 * directory, just next to it. */
3153 log_error_errno(r, "Failed to determine whether directory %s is mount point: %m", arg_directory);
3211 log_error("Directory %s doesn't look like an OS root directory (os-release file is missing). Refusing.", arg_directory);
3243 log_error_errno(errno, "Failed to create temporary directory: %m");