No Graceful Degradation for Missing Tools #19
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
If smartctl, nvme, ceph, or pct commands are missing, the script fails loudly. It should report to run this script to install them (curl -s http://10.10.10.63:3000/LotusGuild/freshStartScript/raw/branch/main/freshStart.sh | bash)
Add tool detection:
def _check_tool_availability(self):
"""Check if required tools are available."""
required_tools = {
'smartctl': 'smartmontools',
'lsblk': 'util-linux',
}
optional_tools = {
'nvme': 'nvme-cli',
'ceph': 'ceph-common',
'pct': 'proxmox-ve',
}