summaryrefslogtreecommitdiff
path: root/cloudinit/config
diff options
context:
space:
mode:
Diffstat (limited to 'cloudinit/config')
-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" % \