agent: fix a bug in update_ephemeral_mounts()

There's a bug in function update_ephemeral_mounts() which only handles
the first storage object and ignores all other storage objects.

Fixes: #7551

Signed-off-by: Jiang Liu <gerry@linux.alibaba.com>
This commit is contained in:
Jiang Liu 2023-08-06 10:46:01 +08:00
parent 5333618d70
commit 98ba211a34

View File

@ -314,14 +314,14 @@ pub async fn update_ephemeral_mounts(
"mount-options" => options.as_str(), "mount-options" => options.as_str(),
); );
return baremount( baremount(
src_path, src_path,
mount_path, mount_path,
storage.fstype.as_str(), storage.fstype.as_str(),
flags, flags,
options.as_str(), options.as_str(),
&logger, &logger,
); )?;
} }
} }
_ => { _ => {