fix typos
This commit is contained in:
parent
4da2516b09
commit
c2104d756b
@ -23,7 +23,7 @@ from octane.util import ssh
|
||||
|
||||
class ComputeUpgrade(upgrade.UpgradeHandler):
|
||||
def prepare(self):
|
||||
self.create_extra_partition()
|
||||
self.create_configdrive_partition()
|
||||
self.preserve_partition()
|
||||
disk.update_node_partition_info(self.node.id)
|
||||
|
||||
@ -67,7 +67,7 @@ class ComputeUpgrade(upgrade.UpgradeHandler):
|
||||
'xargs -I% nova stop %']
|
||||
out, err = ssh.call(cmd, stdout=ssh.PIPE, node=self.node)
|
||||
|
||||
def create_extra_partition(self):
|
||||
def create_configdrive_partition(self):
|
||||
disks = disk.get_node_disks(self.node)
|
||||
if not disks:
|
||||
raise Exception("No disks info was found "
|
||||
|
@ -11,14 +11,12 @@
|
||||
# under the License.
|
||||
import os.path
|
||||
|
||||
from fuelclient.objects import node as node_obj
|
||||
|
||||
from octane.util import docker
|
||||
from octane.util import ssh
|
||||
|
||||
|
||||
def get_node_disks(node):
|
||||
return node_obj.get_attribute(node, 'disks')
|
||||
return node.get_attribute('disks')
|
||||
|
||||
|
||||
def parse_last_partition_end(out):
|
||||
@ -37,7 +35,7 @@ def create_partition(disk_name, size, node):
|
||||
start = parse_last_partition_end(out) + 1
|
||||
end = start + size
|
||||
ssh.call(['parted', '/dev/%s' % disk_name, 'unit', 'MB', 'mkpart',
|
||||
'custom', 'ext4', start, end],
|
||||
'custom', 'ext4', str(start), str(end)],
|
||||
node=node)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user