1
0
mirror of https://github.com/ceph/ceph synced 2025-04-01 23:02:17 +00:00

ceph-volume lvm create should check for root

Signed-off-by: Alfredo Deza <adeza@redhat.com>
This commit is contained in:
Alfredo Deza 2017-08-04 10:11:37 -04:00
parent 74e977fe93
commit a77dc50787

View File

@ -1,6 +1,7 @@
from __future__ import print_function from __future__ import print_function
from textwrap import dedent from textwrap import dedent
from ceph_volume.util import system from ceph_volume.util import system
from ceph_volume import decorators
from .common import create_parser from .common import create_parser
from .prepare import Prepare from .prepare import Prepare
from .activate import Activate from .activate import Activate
@ -13,6 +14,7 @@ class Create(object):
def __init__(self, argv): def __init__(self, argv):
self.argv = argv self.argv = argv
@decorators.needs_root
def create(self, args): def create(self, args):
if not args.osd_fsid: if not args.osd_fsid:
args.osd_fsid = system.generate_uuid() args.osd_fsid = system.generate_uuid()