system: use last mountpoint like before
This commit is contained in:
+1
-3
@@ -324,8 +324,6 @@ async function getBlockDevices() {
|
||||
|
||||
const devices = info.blockdevices.filter(d => d.fstype === 'ext4' || d.fstype === 'xfs');
|
||||
|
||||
debug(`getBlockDevices: Found ${devices.length} devices. ${devices.map(d => d.name).join(', ')}`);
|
||||
|
||||
return devices.map(function (d) {
|
||||
return {
|
||||
path: d.name,
|
||||
@@ -333,7 +331,7 @@ async function getBlockDevices() {
|
||||
type: d.fstype,
|
||||
uuid: d.uuid,
|
||||
rota: d.rota, // false (ssd) true (hdd) . unforuntately, this is not set correctly when virtualized (like in DO)
|
||||
mountpoint: Array.isArray(d.mountpoints) ? d.mountpoints[0] : d.mountpoint // we only support one mountpoint here old lsblk only exposed one via .mountpoint
|
||||
mountpoint: Array.isArray(d.mountpoints) ? d.mountpoints[d.mountpoints.length-1] : d.mountpoint // we only support one mountpoint here old lsblk only exposed one via .mountpoint
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user