]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume util do not use stdin for luminous
authorAlfredo Deza <adeza@redhat.com>
Tue, 31 Jul 2018 20:46:41 +0000 (16:46 -0400)
committerAlfredo Deza <adeza@redhat.com>
Wed, 1 Aug 2018 11:15:37 +0000 (07:15 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
src/ceph-volume/ceph_volume/util/prepare.py

index c1fd5e64d34adc1caf5b8729a472271877a7058e..dbd2a079d795193a6941e192d15d0ec8a114c3cd 100644 (file)
@@ -7,7 +7,7 @@ the single-call helper
 import os
 import logging
 import json
-from ceph_volume import process, conf
+from ceph_volume import process, conf, __release__
 from ceph_volume.util import system, constants
 
 logger = logging.getLogger(__name__)
@@ -365,13 +365,20 @@ def osd_mkfs_filestore(osd_id, fsid, keyring):
         '--mkfs',
         '-i', osd_id,
         '--monmap', monmap,
-        '--keyfile', '-', # goes through stdin
+    ]
+
+    if __release__ != 'luminous':
+        # goes through stdin
+        command.extend(['--keyfile', '-'])
+
+    command.extend([
         '--osd-data', path,
         '--osd-journal', journal,
         '--osd-uuid', fsid,
         '--setuser', 'ceph',
         '--setgroup', 'ceph'
-    ]
+    ])
+
     _, _, returncode = process.call(
         command, stdin=keyring, terminal_verbose=True, show_command=True
     )