diff --git a/src/cloudron.js b/src/cloudron.js index 062b7ee85..828d7e9c1 100644 --- a/src/cloudron.js +++ b/src/cloudron.js @@ -339,14 +339,14 @@ async function getBlockDevices() { let info; try { - info = JSON.parse(execSync('lsblk --paths --json --list --bytes', { encoding: 'utf8' })); + info = JSON.parse(execSync('lsblk --paths --json --list --fs', { encoding: 'utf8' })); } catch (e) { console.error('Failed to list disks:', e); throw new BoxError(BoxError.INTERNAL_ERROR, e); } - // remove empty disks (disks with partitions) - const devices = info.blockdevices.filter(d => d.size); + // filter only for ext4 disks + const devices = info.blockdevices.filter(d => d.fstype === 'ext4'); debug(`getBlockDevices: Found ${devices.length} devices. ${devices.map(d => d.name).join(', ')}`);