Skip to content

Commit

Permalink
fix(client): rename cmd for nbd-client to cmd_nbd
Browse files Browse the repository at this point in the history
Signed-off-by: Syeda Shagufta Naaz <[email protected]>
  • Loading branch information
Syeda Shagufta Naaz committed Feb 5, 2025
1 parent 8ef3493 commit ebd7e35
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mtda/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,9 @@ def pastebin_endpoint(self):
return self._agent.pastebin_endpoint()

def storage_network(self, remote):
cmd = '/usr/sbin/nbd-client'
if os.path.exists(cmd) is False:
raise RuntimeError(f'{cmd} not found')
cmd_nbd = '/usr/sbin/nbd-client'
if os.path.exists(cmd_nbd) is False:
raise RuntimeError(f'{cmd_nbd} not found')

rdev = self._impl.storage_network()
if rdev is None:
Expand All @@ -112,7 +112,7 @@ def storage_network(self, remote):
cmd = ['sudo', '/usr/sbin/modprobe', 'nbd']
subprocess.check_call(cmd)

cmd = ['sudo', cmd, '-N', 'mtda-storage', remote]
cmd = ['sudo', cmd_nbd, '-N', 'mtda-storage', remote]
subprocess.check_call(cmd)

def storage_open(self):
Expand Down

0 comments on commit ebd7e35

Please sign in to comment.