diff --git a/src/mounts.js b/src/mounts.js index dfa295d1b..d5726f28f 100644 --- a/src/mounts.js +++ b/src/mounts.js @@ -152,7 +152,7 @@ async function getStatus(mountType, hostPath) { if (mountType === 'filesystem') return { state: 'active', message: 'Mounted' }; - const [error] = await safe(shell.exec(`mountpoint -q -- ${hostPath}`, { timeout: 5000 })); + const [error] = await safe(shell.promises.exec('getVolumeStatus', `mountpoint -q -- ${hostPath}`, { timeout: 5000 })); const state = error ? 'inactive' : 'active'; if (mountType === 'mountpoint') return { state, message: state === 'active' ? 'Mounted' : 'Not mounted' }; diff --git a/src/storage/filesystem.js b/src/storage/filesystem.js index 9ca3dc63b..bc616fe14 100644 --- a/src/storage/filesystem.js +++ b/src/storage/filesystem.js @@ -257,7 +257,7 @@ async function testConfig(apiConfig) { } if (apiConfig.provider === PROVIDER_MOUNTPOINT) { - const [error] = await safe(shell.exec(`mountpoint -q -- ${apiConfig.mountPoint}`, { timeout: 5000 })); + const [error] = await safe(shell.promises.exec('testStorageConfig', `mountpoint -q -- ${apiConfig.mountPoint}`, { timeout: 5000 })); if (error) throw new BoxError(BoxError.BAD_FIELD, `${apiConfig.mountPoint} is not mounted: ${error.message}`); }