From: Adam King Date: Mon, 13 Feb 2023 21:25:38 +0000 (-0500) Subject: mgr/orchestrator: allow deploying raw mode OSDs with --all-available-devices X-Git-Tag: v19.0.0~1615^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c034b08d952467a99be35a8cf6fc02834eb9a933;p=ceph.git mgr/orchestrator: allow deploying raw mode OSDs with --all-available-devices Fixes: https://tracker.ceph.com/issues/58714 Signed-off-by: Adam King --- diff --git a/src/pybind/mgr/orchestrator/module.py b/src/pybind/mgr/orchestrator/module.py index cc97612ad6a8..4424ff2c9ab0 100644 --- a/src/pybind/mgr/orchestrator/module.py +++ b/src/pybind/mgr/orchestrator/module.py @@ -876,6 +876,7 @@ class OrchestratorCli(OrchestratorClientMixin, MgrModule, unmanaged: Optional[bool] = None, dry_run: bool = False, no_overwrite: bool = False, + method: Optional[OSDMethod] = None, inbuf: Optional[str] = None # deprecated. Was deprecated before Quincy ) -> HandleCommandResult: """ @@ -918,7 +919,8 @@ class OrchestratorCli(OrchestratorClientMixin, MgrModule, placement=PlacementSpec(host_pattern='*'), data_devices=DeviceSelection(all=True), unmanaged=unmanaged, - preview_only=dry_run + preview_only=dry_run, + method=method ) ] return self._apply_misc(dg_specs, dry_run, format, no_overwrite) diff --git a/src/python-common/ceph/deployment/drive_group.py b/src/python-common/ceph/deployment/drive_group.py index 3141fd760e53..e8ee85885f67 100644 --- a/src/python-common/ceph/deployment/drive_group.py +++ b/src/python-common/ceph/deployment/drive_group.py @@ -15,6 +15,9 @@ class OSDMethod(str, enum.Enum): raw = 'raw' lvm = 'lvm' + def to_json(self) -> str: + return self.value + class DeviceSelection(object): """