]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
Revert "cv: support zap by osd fsid" v3.2.15
authorGuillaume Abrioux <gabrioux@redhat.com>
Thu, 25 Apr 2019 15:45:46 +0000 (17:45 +0200)
committerGuillaume Abrioux <gabrioux@redhat.com>
Thu, 25 Apr 2019 19:27:37 +0000 (21:27 +0200)
This reverts commit 8454f0144af10834da0cddb508a5dea11bda3c72.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
library/ceph_volume.py
library/test_ceph_volume.py

index 4d45551c3c5d7fff4d4209c7084e1a1362fbcb31..5212104d9cdbf0b40d070040bf7dde6a7729750d 100644 (file)
@@ -48,10 +48,6 @@ options:
         description:
             - If data is a lv, this must be the name of the volume group it belongs to.
         required: false
-    osd_fsid:
-        description:
-            - The OSD FSID
-        required: false
     journal:
         description:
             - The logical volume name or partition to use as a filestore journal.
@@ -428,7 +424,7 @@ def zap_devices(module, container_image):
     '''
 
     # get module variables
-    data = module.params.get('data', None)
+    data = module.params['data']
     data_vg = module.params.get('data_vg', None)
     journal = module.params.get('journal', None)
     journal_vg = module.params.get('journal_vg', None)
@@ -436,19 +432,13 @@ def zap_devices(module, container_image):
     db_vg = module.params.get('db_vg', None)
     wal = module.params.get('wal', None)
     wal_vg = module.params.get('wal_vg', None)
-    osd_fsid = module.params.get('osd_fsid', None)
+    data = get_data(data, data_vg)
 
     # build the CLI
     action = 'zap'
     cmd = build_ceph_volume_cmd(action, container_image)
     cmd.append('--destroy')
-
-    if osd_fsid:
-        cmd.extend(['--osd-fsid', osd_fsid])
-
-    if data:
-        data = get_data(data, data_vg)
-        cmd.append(data)
+    cmd.append(data)
 
     if journal:
         journal = get_journal(journal, journal_vg)
@@ -488,7 +478,6 @@ def run_module():
         block_db_size=dict(type='str', required=False, default='-1'),
         report=dict(type='bool', required=False, default=False),
         containerized=dict(type='str', required=False, default=False),
-        osd_fsid=dict(type='str', required=False),
     )
 
     module = AnsibleModule(
index df020e47928c779a5f154200cd795e15851ad619..7241850086bab120f17dbf97e498072e28441b59 100644 (file)
@@ -83,19 +83,6 @@ class TestCephVolumeModule(object):
         result = ceph_volume.zap_devices(fake_module, fake_container_image)
         assert result == expected_command_list
 
-    def test_zap_osd_fsid(self):
-        fake_module = MagicMock()
-        fake_module.params = {'osd_fsid': 'a_uuid'}
-        fake_container_image = None
-        expected_command_list = ['ceph-volume',
-                                 'lvm',
-                                 'zap',
-                                 '--destroy',
-                                 '--osd-fsid',
-                                 'a_uuid']
-        result = ceph_volume.zap_devices(fake_module, fake_container_image)
-        assert result == expected_command_list
-
     def test_activate_osd(self):
         expected_command_list = ['ceph-volume',
                                  'lvm',