summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Lehman <dlehman@redhat.com>2012-11-28 16:42:09 -0600
committerDavid Lehman <dlehman@redhat.com>2012-11-29 20:12:31 -0600
commit3ff52c6e4d3781b8e9dc0c93d8c6ba1521feabf2 (patch)
tree8b4a99b708ce01598e8ae9f2ff1810b2d51b67e3
parentd22ac6f1fee5dfddc0d7eacbc5ca826e06909e83 (diff)
downloadanaconda-3ff52c6e4d3781b8e9dc0c93d8c6ba1521feabf2.tar.gz
anaconda-3ff52c6e4d3781b8e9dc0c93d8c6ba1521feabf2.tar.xz
anaconda-3ff52c6e4d3781b8e9dc0c93d8c6ba1521feabf2.zip
Don't let defaults override user-specified container settings. (#879702)
-rw-r--r--pyanaconda/ui/gui/spokes/custom.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index 0ed7e127b..01d56ecae 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -1773,6 +1773,16 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
self.clear_errors()
with ui_storage_logger():
+ factory = self.__storage.getDeviceFactory(device_type, size)
+ container = self.__storage.getContainer(factory)
+
+ if container:
+ # don't override user-initiated changes to a defined container
+ if factory.encrypt_members:
+ encrypted = container.encrypted
+
+ disks = container.disks
+
try:
self.__storage.newDevice(device_type,
size=size,
@@ -1789,7 +1799,6 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
except StorageError as e:
log.error("newDevice failed: %s" % e)
log.debug("trying to find an existing container to use")
- factory = self.__storage.getDeviceFactory(device_type, size)
container = self.__storage.getContainer(factory, existing=True)
log.debug("found container %s" % container)
if container: