summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/pybind/mgr/cephadm/module.py4
-rw-r--r--src/pybind/mgr/cephadm/tests/test_cephadm.py2
-rw-r--r--src/pybind/mgr/orchestrator.py2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py
index 550c07c6247..78b7edb117b 100644
--- a/src/pybind/mgr/cephadm/module.py
+++ b/src/pybind/mgr/cephadm/module.py
@@ -902,13 +902,13 @@ class CephadmOrchestrator(MgrModule, orchestrator.Orchestrator):
def blink_device_light(self, ident_fault, on, locs):
@async_map_completion
- def blink(host, dev):
+ def blink(host, dev, path):
cmd = [
'lsmcli',
'local-disk-%s-led-%s' % (
ident_fault,
'on' if on else 'off'),
- '--path', dev,
+ '--path', path or dev,
]
out, err, code = self._run_cephadm(
host, 'osd', 'shell', ['--'] + cmd,
diff --git a/src/pybind/mgr/cephadm/tests/test_cephadm.py b/src/pybind/mgr/cephadm/tests/test_cephadm.py
index c93353d5bd8..6cda1902dc5 100644
--- a/src/pybind/mgr/cephadm/tests/test_cephadm.py
+++ b/src/pybind/mgr/cephadm/tests/test_cephadm.py
@@ -211,5 +211,5 @@ class TestCephadm(object):
@mock.patch("cephadm.module.CephadmOrchestrator._get_connection")
def test_blink_device_light(self, _send_command, _get_connection, cephadm_module):
with self._with_host(cephadm_module, 'test'):
- c = cephadm_module.blink_device_light('ident', True, [('test', '')])
+ c = cephadm_module.blink_device_light('ident', True, [('test', '', '')])
assert self._wait(cephadm_module, c) == ['Set ident light for test: on']
diff --git a/src/pybind/mgr/orchestrator.py b/src/pybind/mgr/orchestrator.py
index 27d3b8f3d35..4d4b672d0c6 100644
--- a/src/pybind/mgr/orchestrator.py
+++ b/src/pybind/mgr/orchestrator.py
@@ -1398,7 +1398,7 @@ class InventoryNode(object):
return self.name == other.name and self.devices == other.devices
-class DeviceLightLoc(namedtuple('DeviceLightLoc', ['host', 'dev'])):
+class DeviceLightLoc(namedtuple('DeviceLightLoc', ['host', 'dev', 'path'])):
"""
Describes a specific device on a specific host. Used for enabling or disabling LEDs
on devices.