summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2013-09-27 15:45:56 -0400
committerScott Moser <smoser@ubuntu.com>2013-09-27 15:45:56 -0400
commit1388890380ed4edf47c2ad0421cedfc117f44cdd (patch)
tree6ca4aa17d27f6bd601eb940a6b61e2d5453498de
parent7c7ba39a8f40530172f7f9d91592b2cf1d402f87 (diff)
downloadvyos-cloud-init-1388890380ed4edf47c2ad0421cedfc117f44cdd.tar.gz
vyos-cloud-init-1388890380ed4edf47c2ad0421cedfc117f44cdd.zip
update to get functional with any alias in a 'device' entry
-rw-r--r--cloudinit/config/cc_disk_setup.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/cloudinit/config/cc_disk_setup.py b/cloudinit/config/cc_disk_setup.py
index a170f81f..85e184cb 100644
--- a/cloudinit/config/cc_disk_setup.py
+++ b/cloudinit/config/cc_disk_setup.py
@@ -514,9 +514,6 @@ def mkpart(device, cloud, definition):
LOG.debug("Checking against default devices")
if _device and (_device != device):
if not is_device_valid(_device):
- _device = _device[:-1]
-
- if not is_device_valid(_device):
raise Exception("Unable to find backing block device for %s" % \
device)
else:
@@ -586,7 +583,7 @@ def mkfs(cloud, fs_cfg):
# This allows you to define the default ephemeral or swap
LOG.debug("Checking %s against default devices" % device)
- _device = is_default_device(label, cloud, fallback=device)
+ _device = is_default_device(device, cloud, fallback=device)
if _device and (_device != device):
if not is_device_valid(_device):
raise Exception("Unable to find backing block device for %s" % \