auto lib_dir = ModifyDirectories(b.GetStringArray(kAulMountLibDir));
if (!lib_dir.empty()) {
auto root_path = b.GetString(kAulRootPath);
- MountDirectories(lib_dir, root_path + "/lib/");
+ auto dest = root_path + "/bin/.rpk/";
+ if (access(dest.c_str(), F_OK) != 0) {
+ auto app_type = b.GetString(kAulAppType);
+ if (app_type.find("dotnet") != std::string::npos)
+ dest = root_path + "/bin/";
+ else
+ dest = root_path + "/lib/";
+ }
+
+ MountDirectories(lib_dir, dest);
}
return 0;
if (!gadget_paths.empty()) {
gadget_paths = ValidateAndModifyGadgetPaths(gadget_paths);
auto root_path = b.GetString(kAulRootPath);
- return MountDirectories(gadget_paths, root_path + "/bin");
+ auto dest = root_path + "/bin/.rpk/";
+ if (access(dest.c_str(), F_OK) != 0) dest = root_path + "/bin/";
+
+ return MountDirectories(gadget_paths, dest);
}
return 0;