From 1388890380ed4edf47c2ad0421cedfc117f44cdd Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Fri, 27 Sep 2013 15:45:56 -0400 Subject: update to get functional with any alias in a 'device' entry --- cloudinit/config/cc_disk_setup.py | 5 +---- 1 file changed, 1 insertion(+), 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 @@ -513,9 +513,6 @@ def mkpart(device, cloud, definition): # Check if the default device is a partition or not 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) @@ -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" % \ -- cgit v1.2.3