[master/rhel7-branch] Change the accelerator key for Add DASD label. (#1070115)
by Samantha N. Bueno
Avoid collisions with other accelerator keys.
Related: rhbz#1070115
---
pyanaconda/ui/gui/spokes/filter.glade | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/filter.glade b/pyanaconda/ui/gui/spokes/filter.glade
index 88e736c..07fb4f2 100644
--- a/pyanaconda/ui/gui/spokes/filter.glade
+++ b/pyanaconda/ui/gui/spokes/filter.glade
@@ -1640,7 +1640,7 @@
</child>
<child>
<object class="GtkButton" id="addDASDButton">
- <property name="label" translatable="yes">Add _DASD...</property>
+ <property name="label" translatable="yes">Add EC_KD DASD...</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
--
1.9.3
9 years, 9 months
[PATCH] Remove the --disable-overwrite option
by Martin Kolman
As has been found out on IRC, this option has just been copied over when
various components were split from Anaconda, but it actually does not bring
any benefit and should be removed.
Martin Kolman (1):
Remove the --disable-overwrite parameter for the Transifex client
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
1.9.3
9 years, 9 months
[blivet:master] Get rid of misleading comment (#1066721)
by Anne Mulhern
Related: fed#1066721
Should have gone in with commit 1f8c93ecf1be236fd4ec2f00bf64fd2c69246761.
Signed-off-by: mulhern <amulhern(a)redhat.com>
---
blivet/size.py | 1 -
1 file changed, 1 deletion(-)
diff --git a/blivet/size.py b/blivet/size.py
index b9f0089..4c23c11 100644
--- a/blivet/size.py
+++ b/blivet/size.py
@@ -224,7 +224,6 @@ class Size(Decimal):
return self
def __str__(self, eng=False, context=None):
- # Convert the result of humanReadable from unicode to str
return self.humanReadable()
def __repr__(self):
--
1.9.3
9 years, 9 months
[master/rhel7-branch] Fix q for quit issue in text mode (#997405)
by Samantha N. Bueno
Pressing 'q' to quit the installer in the ask VNC spoke of text mode was
not working. We can't rely on the global handling of this input,
unfortunately, since the installation environment is not set up at this
point. But, this should be a relatively simple way of adding the
functionality.
Resolves: rhbz#997405
---
pyanaconda/ui/tui/spokes/askvnc.py | 35 +++++++++++++++++++++--------------
1 file changed, 21 insertions(+), 14 deletions(-)
diff --git a/pyanaconda/ui/tui/spokes/askvnc.py b/pyanaconda/ui/tui/spokes/askvnc.py
index 200a5a6..52548f4 100644
--- a/pyanaconda/ui/tui/spokes/askvnc.py
+++ b/pyanaconda/ui/tui/spokes/askvnc.py
@@ -21,9 +21,10 @@
from pyanaconda.ui.tui.spokes import NormalTUISpoke
from pyanaconda.ui.tui.simpleline import TextWidget, ColumnWidget
+from pyanaconda.ui.tui.tuiobject import YesNoDialog
from pyanaconda.constants import USEVNC, USETEXT
from pyanaconda.i18n import N_, _
-import getpass
+import getpass, subprocess
class AskVNCSpoke(NormalTUISpoke):
title = N_("VNC")
@@ -68,22 +69,28 @@ class AskVNCSpoke(NormalTUISpoke):
"""Override input so that we can launch the VNC password spoke"""
try:
- number = int(key)
- choice = self._choices[number -1]
+ choice = self._choices[int(key) - 1]
+ if choice == USETEXT:
+ self._usevnc = False
+ else:
+ self._usevnc = True
+ newspoke = VNCPassSpoke(self.app, self.data, self.storage,
+ self.payload, self.instclass)
+ self.app.switch_screen_modal(newspoke)
+
+ self.apply()
+ self.close()
+ return None
except (ValueError, KeyError, IndexError):
- return key
+ pass
- if choice == USETEXT:
- self._usevnc = False
+ if key.lower() == _('q'):
+ d = YesNoDialog(self.app, _(self.app.quit_message))
+ self.app.switch_screen_modal(d)
+ if d.answer:
+ subprocess.Popen(["systemctl", "--no-wall", "reboot"])
else:
- self._usevnc = True
- newspoke = VNCPassSpoke(self.app, self.data, self.storage,
- self.payload, self.instclass)
- self.app.switch_screen_modal(newspoke)
-
- self.apply()
- self.close()
- return None
+ return key
def apply(self):
self.data.vnc.enabled = self._usevnc
--
1.9.3
9 years, 9 months
[PATCH rhel7-branch] tui: show software and source spoke iff payload is PackagePayload (#1139142)
by Radek Vykydal
Resolves: rhbz#1139142
The same what we do in GUI in
commit b2730604a2089236ebb94c22d96bbacc71235c59
---
pyanaconda/ui/tui/spokes/software.py | 4 ++--
pyanaconda/ui/tui/spokes/source.py | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/pyanaconda/ui/tui/spokes/software.py b/pyanaconda/ui/tui/spokes/software.py
index 9ce2d94..deb4254 100644
--- a/pyanaconda/ui/tui/spokes/software.py
+++ b/pyanaconda/ui/tui/spokes/software.py
@@ -23,7 +23,7 @@ from pyanaconda.flags import flags
from pyanaconda.ui.tui.spokes import NormalTUISpoke
from pyanaconda.ui.tui.simpleline import TextWidget, ColumnWidget, CheckboxWidget
from pyanaconda.threads import threadMgr, AnacondaThread
-from pyanaconda.packaging import DependencyError
+from pyanaconda.packaging import DependencyError, PackagePayload
from pyanaconda.i18n import N_, _
from pyanaconda.constants import THREAD_PAYLOAD
@@ -53,7 +53,7 @@ class SoftwareSpoke(NormalTUISpoke):
@property
def showable(self):
- return not flags.livecdInstall and not self.data.method.method == "liveimg"
+ return isinstance(self.payload, PackagePayload)
@property
def status(self):
diff --git a/pyanaconda/ui/tui/spokes/source.py b/pyanaconda/ui/tui/spokes/source.py
index 3bc7aa4..b7940b6 100644
--- a/pyanaconda/ui/tui/spokes/source.py
+++ b/pyanaconda/ui/tui/spokes/source.py
@@ -25,7 +25,7 @@ from pyanaconda.ui.tui.spokes import EditTUISpoke, NormalTUISpoke
from pyanaconda.ui.tui.spokes import EditTUISpokeEntry as Entry
from pyanaconda.ui.tui.simpleline import TextWidget, ColumnWidget
from pyanaconda.threads import threadMgr, AnacondaThread
-from pyanaconda.packaging import payloadMgr
+from pyanaconda.packaging import payloadMgr, PackagePayload
from pyanaconda.i18n import N_, _
from pyanaconda.image import opticalInstallMedia, potentialHdisoSources
from pyanaconda.iutil import DataHolder
@@ -207,7 +207,7 @@ class SourceSpoke(SourceSwitchHandler, EditTUISpoke):
@property
def showable(self):
- return not flags.livecdInstall and not self.data.method.method == "liveimg"
+ return isinstance(self.payload, PackagePayload)
@property
def status(self):
--
1.9.3
9 years, 9 months
[PATCH rhel7-branch] network: add s390 network ifcfg options also for bond slaves (#1090558)
by Radek Vykydal
Resolves: rhbz#1090558
---
dracut/parse-kickstart | 20 ++++++++++++--------
1 file changed, 12 insertions(+), 8 deletions(-)
diff --git a/dracut/parse-kickstart b/dracut/parse-kickstart
index a8ece63..1e46b35 100755
--- a/dracut/parse-kickstart
+++ b/dracut/parse-kickstart
@@ -313,6 +313,16 @@ def ksnet_to_dracut(args, lineno, net, bootdev=False):
return " ".join(line)
+def add_s390_settings(dev, ifcfg):
+ s390cfg = s390_settings(dev)
+ if s390cfg['SUBCHANNELS']:
+ ifcfg.pop('HWADDR')
+ ifcfg['SUBCHANNELS'] = s390cfg['SUBCHANNELS']
+ if s390cfg['NETTYPE']:
+ ifcfg['NETTYPE'] = s390cfg['NETTYPE']
+ if s390cfg['OPTIONS']:
+ ifcfg['OPTIONS'] = s390cfg['OPTIONS']
+
def ksnet_to_ifcfg(net, filename=None):
'''Write an ifcfg file for the given kickstart network config'''
dev = net.device
@@ -336,14 +346,7 @@ def ksnet_to_ifcfg(net, filename=None):
# we use it to activate devcies by NM on start
ifcfg['ONBOOT'] = "yes" if net.activate else "no"
- s390cfg = s390_settings(dev)
- if s390cfg['SUBCHANNELS']:
- ifcfg.pop('HWADDR')
- ifcfg['SUBCHANNELS'] = s390cfg['SUBCHANNELS']
- if s390cfg['NETTYPE']:
- ifcfg['NETTYPE'] = s390cfg['NETTYPE']
- if s390cfg['OPTIONS']:
- ifcfg['OPTIONS'] = s390cfg['OPTIONS']
+ add_s390_settings(dev, ifcfg)
# dhcp etc.
ifcfg['BOOTPROTO'] = net.bootProto
@@ -412,6 +415,7 @@ def ksnet_to_ifcfg(net, filename=None):
'MASTER' : dev,
'HWADDR' : readsysfile("/sys/class/net/%s/address" % slave),
}
+ add_s390_settings(slave, slave_ifcfg)
slave_filename = "/tmp/ifcfg/ifcfg-%s" % "_".join(slave_ifcfg['NAME'].split(" "))
log.info("writing ifcfg %s for slave %s of bond %s" % (slave_filename, slave, dev))
write_ifcfg(slave_filename, slave_ifcfg)
--
1.9.3
9 years, 9 months
[PATCH rhel6-branch] Revert "Use edd fcoe boot option instead of enumerating all ifaces" (#1103920)
by Radek Vykydal
This reverts commit 479cb1ca481b88b9cd2e861be03dd2c28d32e18c.
Resolves: rhbz#1103920
We can revert the change for #909463 now that the bz issue is properly
fixed in dracut (#1022766)
The original issue was that dracut connected to LUNs only via interface
specified by the last of fcoe:<ifaceX>... boot options which made multipath
cases with this last interface not physically connected during boot not work
(boot). Patched dracut now connects to LUNs via all interfaces specified by
fcoe:<ifaceX> commands which makes anaconda patch we are reverting no longer
needed.
---
storage/devices.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/storage/devices.py b/storage/devices.py
index c50c01c..e179339 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -3782,7 +3782,10 @@ class FcoeDiskDevice(DiskDevice, NetworkStorageDevice):
else:
dcbOpt = "nodcb"
- return set(["fcoe=edd:%s" % dcbOpt])
+ if nic in fcoe().ksnics:
+ return set(["fcoe=%s:%s" % (nic, dcbOpt)])
+ else:
+ return set(["fcoe=edd:%s" % dcbOpt])
class OpticalDevice(StorageDevice):
--
1.9.3
9 years, 9 months
[PATCH] Let finding install classes be more flexible for Fedora (#1138820).
by Chris Lumens
(1) Make it so a valid install class does not have to be named "InstallClass"
which should make inheritance less cumbersome.
(2) Allow putting more than one install class into a single file.
(3) Rename the existing install classes to be <distro>BaseInstallClass. This
makes it more clear for subclasses where they're coming from.
---
pyanaconda/installclass.py | 16 ++++++----------
pyanaconda/installclasses/fedora.py | 2 +-
pyanaconda/installclasses/rhel.py | 2 +-
3 files changed, 8 insertions(+), 12 deletions(-)
diff --git a/pyanaconda/installclass.py b/pyanaconda/installclass.py
index 4fd8865..3a52f65 100644
--- a/pyanaconda/installclass.py
+++ b/pyanaconda/installclass.py
@@ -185,7 +185,6 @@ def availableClasses(showHidden=0):
continue
done[mainName] = 1
-
try:
found = imputil.imp.find_module(mainName)
except ImportError:
@@ -195,15 +194,12 @@ def availableClasses(showHidden=0):
try:
loaded = imputil.imp.load_module(mainName, found[0], found[1], found[2])
- obj = loaded.InstallClass
-
- if 'sortPriority' in obj.__dict__:
- sortOrder = obj.sortPriority
- else:
- sortOrder = 0
-
- if obj.hidden == 0 or showHidden == 1:
- lst.append(((obj.name, obj), sortOrder))
+ for (_key, obj) in loaded.__dict__.items():
+ # If it's got these two methods, it's an InstallClass.
+ if hasattr(obj, "setDefaultPartitioning") and hasattr(obj, "setPackageSelection"):
+ sortOrder = getattr(obj, "sortPriority", 0)
+ if obj.hidden == 0 or showHidden == 1:
+ lst.append(((obj.name, obj), sortOrder))
except (ImportError, AttributeError):
log.warning ("module import of %s failed: %s", mainName, sys.exc_type)
diff --git a/pyanaconda/installclasses/fedora.py b/pyanaconda/installclasses/fedora.py
index 1fe192b..d2dbb73 100644
--- a/pyanaconda/installclasses/fedora.py
+++ b/pyanaconda/installclasses/fedora.py
@@ -23,7 +23,7 @@ from pyanaconda import network
from pyanaconda import nm
from pyanaconda.i18n import N_
-class InstallClass(BaseInstallClass):
+class FedoraBaseInstallClass(BaseInstallClass):
# name has underscore used for mnemonics, strip if you dont need it
id = "fedora"
name = N_("_Fedora")
diff --git a/pyanaconda/installclasses/rhel.py b/pyanaconda/installclasses/rhel.py
index ed8511e..5931432 100644
--- a/pyanaconda/installclasses/rhel.py
+++ b/pyanaconda/installclasses/rhel.py
@@ -23,7 +23,7 @@ from pyanaconda.product import productName
from pyanaconda import network
from pyanaconda import nm
-class InstallClass(BaseInstallClass):
+class RHELBaseInstallClass(BaseInstallClass):
# name has underscore used for mnemonics, strip if you dont need it
id = "rhel"
name = N_("Red Hat Enterprise Linux")
--
1.9.3
9 years, 9 months
[PATCH blivet rhel7-branch] iscsi: mount partitions in initramfs for root on iscsi (#740106)
by Radek Vykydal
/ and /usr are mounted automatically, for other partitions
x-initrd.mount option is needed in /etc/fstab
Resolves: rhbz#740106
---
blivet/__init__.py | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/blivet/__init__.py b/blivet/__init__.py
index a4264f3..b1cfd8e 100644
--- a/blivet/__init__.py
+++ b/blivet/__init__.py
@@ -2917,6 +2917,10 @@ class FSSet(object):
devices += self.swapDevices
netdevs = self.devicetree.getDevicesByInstance(NetworkStorageDevice)
+
+ rootdev = devices[0]
+ root_on_netdev = any(rootdev.dependsOn(netdev) for netdev in netdevs)
+
for device in devices:
# why the hell do we put swap in the fstab, anyway?
if not device.format.mountable and device.format.type != "swap":
@@ -2943,6 +2947,8 @@ class FSSet(object):
for netdev in netdevs:
if device.dependsOn(netdev):
options = options + ",_netdev"
+ if root_on_netdev and device.format.mountpoint not in ["/", "/usr"]:
+ options = options + ",x-initrd.mount"
break
if device.encrypted:
options += ",x-systemd.device-timeout=0"
--
1.9.3
9 years, 9 months
[blivet:master] Fixes for a bug in Size.humanReadable (v2)
by Anne Mulhern
Actually, this is a comprehensive overhaul of the method.
mulhern (1):
Fixes to Size.humanReadable() method
blivet/size.py | 90 ++++++++++++++++++++++++++++++------------------------
tests/size_test.py | 58 ++++++++++++++++++++++++++++++-----
2 files changed, 100 insertions(+), 48 deletions(-)
--
1.9.3
9 years, 9 months