diff --git a/src/runtime-rs/crates/agent/src/kata/trans.rs b/src/runtime-rs/crates/agent/src/kata/trans.rs index eec571a558..fba1f1954c 100644 --- a/src/runtime-rs/crates/agent/src/kata/trans.rs +++ b/src/runtime-rs/crates/agent/src/kata/trans.rs @@ -114,6 +114,7 @@ impl From for agent::Storage { fs_group: from_option(from.fs_group), options: trans_vec(from.options), mount_point: from.mount_point, + shared: from.shared, ..Default::default() } } diff --git a/src/runtime-rs/crates/agent/src/types.rs b/src/runtime-rs/crates/agent/src/types.rs index 8e0917b559..2352799c02 100644 --- a/src/runtime-rs/crates/agent/src/types.rs +++ b/src/runtime-rs/crates/agent/src/types.rs @@ -60,6 +60,7 @@ pub struct Storage { pub fs_group: Option, pub options: Vec, pub mount_point: String, + pub shared: bool, } #[derive(PartialEq, Clone, Default)] diff --git a/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_inline.rs b/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_inline.rs index a5d97503af..bf4d00d2e3 100644 --- a/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_inline.rs +++ b/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_inline.rs @@ -89,6 +89,7 @@ impl ShareFs for ShareVirtioFsInline { fs_group: None, options: SHARED_DIR_VIRTIO_FS_OPTIONS.clone(), mount_point: kata_guest_share_dir(), + shared: false, }; storages.push(shared_volume); diff --git a/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_standalone.rs b/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_standalone.rs index 2e181b75af..8e8cbd5b6d 100644 --- a/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_standalone.rs +++ b/src/runtime-rs/crates/resource/src/share_fs/share_virtio_fs_standalone.rs @@ -246,6 +246,7 @@ impl ShareFs for ShareVirtioFsStandalone { fs_group: None, options: vec![String::from("nodev")], mount_point: kata_guest_share_dir(), + shared: false, }; storages.push(shared_volume); diff --git a/src/runtime-rs/crates/resource/src/share_fs/virtio_fs_share_mount.rs b/src/runtime-rs/crates/resource/src/share_fs/virtio_fs_share_mount.rs index 18415c0aeb..61b5eb6d28 100644 --- a/src/runtime-rs/crates/resource/src/share_fs/virtio_fs_share_mount.rs +++ b/src/runtime-rs/crates/resource/src/share_fs/virtio_fs_share_mount.rs @@ -108,6 +108,7 @@ impl ShareFsMount for VirtiofsShareMount { fs_group: None, options: config.mount_options.clone(), mount_point: watchable_guest_mount.clone(), + shared: false, }; // Update the guest_path, in order to identify what will diff --git a/src/runtime-rs/crates/resource/src/volume/ephemeral_volume.rs b/src/runtime-rs/crates/resource/src/volume/ephemeral_volume.rs index c8c794edcf..3c3861294b 100644 --- a/src/runtime-rs/crates/resource/src/volume/ephemeral_volume.rs +++ b/src/runtime-rs/crates/resource/src/volume/ephemeral_volume.rs @@ -67,6 +67,7 @@ impl EphemeralVolume { fs_group: None, options: dir_options, mount_point: source.clone(), + shared: false, }; let mut mount = oci::Mount::default(); diff --git a/src/runtime-rs/crates/resource/src/volume/local_volume.rs b/src/runtime-rs/crates/resource/src/volume/local_volume.rs index 6b82a51fdc..d0f33d8428 100644 --- a/src/runtime-rs/crates/resource/src/volume/local_volume.rs +++ b/src/runtime-rs/crates/resource/src/volume/local_volume.rs @@ -75,6 +75,7 @@ impl LocalStorage { fs_group: None, options: dir_options, mount_point: source.clone(), + shared: false, }; let mounts: Vec = if sid != cid {