[PATCH] Another batch of initial setup related patches
by Martin Sivak
Hi,
the first two patches are quite simple and not at all special. However
the other two are something I had to do to, but it might not be the
best way with regards to anaconda future and maintenance.
3) This patch implements the feature Stef asked for his realmd addon
- he was affraid that customers will regard %addon section in kickstart
as something that is not really supported that well
- so he asked us to look into allowing the addons to define their own
"first class" kickstart command that will not be distinguishable from
the rest
- I see two issues with it. One is validation, and the second is that
when addon is missing, sections are gracefully saved and transfered to
the output kickstart without breaking anaconda. Unknown command raises
an exception.
- Regarding validation.. the whole kickstart addon implementation should
be moved to pykickstart so the validation tools can load the addons as
well.
4) The last patch is a bit hairy and wild. I needed a way to determine if
a spoke was completed in anaconda. Initial-setup loads the
/root/anaconda.ks.cfg file and the code here uses the completed
attribute of spokes. BUT! It does this in the loading phase where the
spokes are not initialized yet so some magic was needed.
Spokes marked for firstboot do not have any storage, instclass or
backend available (all set to None) so if we make it a requirement that
spokes which are to be shared with initial-setup must not use anything
else than self.data in completed property this will work well.
At least the functionality of 1, 2 and 4) has to go to F19 alpha. It can be
implemented differently though. So if you have any idea how to do it better
and cleaner, I would like to hear it.
Martin
11 years, 1 month
[PATCH] Run yum transaction in a different process
by Brian C. Lane
From: "Brian C. Lane" <bcl(a)redhat.com>
This sorta works.
I *think* the remaining problems are rpm's or maybe yum's problems.
With this patch it manages to download the package, check the sha256sum and
then rpm rejects it with an error and gets stuck in a loop somewhere in the rpm
code.
If I manually try to install the rpm it complains that there are missing deps,
which would be a problem for yum.
Brian C. Lane (1):
Execute the yum transaction in another process
pyanaconda/packaging/yumpayload.py | 352 ++++++++++++++++++++++++++-----------
1 file changed, 250 insertions(+), 102 deletions(-)
--
1.8.1.4
11 years, 1 month
[master] Two minor changes for the addon support
by Vratislav Podzimek
These patches bring two minor changes that are useful for addons.
Vratislav Podzimek (2):
Insert newline before the %end string closing the section
Handle the end of the %addon section
pyanaconda/addons.py | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
--
1.7.11.7
11 years, 1 month
[PATCH] Fix a bug I introduced with 3c78c1a5c.
by Chris Lumens
---
pyanaconda/ui/gui/spokes/custom.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index 6fa2f95..a8fda8c 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -803,7 +803,7 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
""" Add an entry for device to the new install Page. """
page = self._accordion._find_by_title(self.translated_new_install_name).get_child()
devices = [device]
- if page.members:
+ if not page.members:
# remove the CreateNewPage and replace it with a regular Page
expander = self._accordion._find_by_title(self.translated_new_install_name)
expander.remove(expander.get_child())
--
1.8.1.2
11 years, 1 month
[PATCH 1/2] Translate the "Create a new volume group..." text (#892782).
by Chris Lumens
---
pyanaconda/ui/gui/spokes/custom.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index defaba7..9d9bd14 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -2030,13 +2030,13 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
if vg_name is None:
return
- if vg_name == new_vg_text:
+ if vg_name == _(new_vg_text):
# run the vg editor dialog with a default name and disk set
hostname = self.data.network.hostname
name = self.__storage.suggestContainerName(hostname=hostname)
self.run_vg_editor(name=name)
for idx, data in enumerate(combo.get_model()):
- if data[0] == new_vg_text:
+ if data[0] == _(new_vg_text):
combo.insert_text(idx, self._device_container_name)
combo.set_active(idx)
break
@@ -2274,7 +2274,7 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
vg_combo.append_text(default_vg)
vg_combo.set_active(len(vg_combo.get_model()) - 1)
- vg_combo.append_text(new_vg_text)
+ vg_combo.append_text(_(new_vg_text))
if default_vg is None:
vg_combo.set_active(len(vg_combo.get_model()) - 1)
--
1.8.1.2
11 years, 1 month
[PATCH] Move the Desired Capacity label and spinner into its own row (#907883, #904999).
by Chris Lumens
All that text plus the spinner, plus the other widgets on the screen, makes the
whole screen too wide to run at 800x600. This seems like a reasonable fix to
the problem.
---
pyanaconda/ui/gui/spokes/custom.glade | 82 +++++++++++++++--------------------
1 file changed, 35 insertions(+), 47 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/custom.glade b/pyanaconda/ui/gui/spokes/custom.glade
index 3f8516a..d0d25db 100644
--- a/pyanaconda/ui/gui/spokes/custom.glade
+++ b/pyanaconda/ui/gui/spokes/custom.glade
@@ -613,24 +613,6 @@ use. Try something else?</property>
</packing>
</child>
<child>
- <object class="GtkLabel" id="label5">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="halign">end</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes"><b>_Desired Capacity (MB):</b></property>
- <property name="use_markup">True</property>
- <property name="use_underline">True</property>
- <property name="mnemonic_widget">sizeSpinner</property>
- </object>
- <packing>
- <property name="left_attach">2</property>
- <property name="top_attach">2</property>
- <property name="width">1</property>
- <property name="height">1</property>
- </packing>
- </child>
- <child>
<object class="GtkEntry" id="labelEntry">
<property name="visible">True</property>
<property name="can_focus">True</property>
@@ -645,24 +627,6 @@ use. Try something else?</property>
</packing>
</child>
<child>
- <object class="GtkSpinButton" id="sizeSpinner">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="halign">end</property>
- <property name="invisible_char">●</property>
- <property name="width_chars">7</property>
- <property name="invisible_char_set">True</property>
- <property name="adjustment">sizeAdjustment</property>
- <property name="numeric">True</property>
- </object>
- <packing>
- <property name="left_attach">3</property>
- <property name="top_attach">2</property>
- <property name="width">1</property>
- <property name="height">1</property>
- </packing>
- </child>
- <child>
<object class="GtkLabel" id="label13">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -695,16 +659,40 @@ use. Try something else?</property>
</packing>
</child>
<child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
+ <object class="GtkLabel" id="label5">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">end</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes"><b>_Desired Capacity (MB):</b></property>
+ <property name="use_markup">True</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">sizeSpinner</property>
+ </object>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
</child>
<child>
- <placeholder/>
+ <object class="GtkSpinButton" id="sizeSpinner">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="halign">end</property>
+ <property name="invisible_char">●</property>
+ <property name="width_chars">7</property>
+ <property name="invisible_char_set">True</property>
+ <property name="adjustment">sizeAdjustment</property>
+ <property name="numeric">True</property>
+ </object>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="top_attach">3</property>
+ <property name="width">1</property>
+ <property name="height">1</property>
+ </packing>
</child>
</object>
<packing>
@@ -899,9 +887,6 @@ use. Try something else?</property>
</packing>
</child>
<child>
- <placeholder/>
- </child>
- <child>
<object class="GtkComboBox" id="raidLevelCombo">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -920,6 +905,9 @@ use. Try something else?</property>
<property name="height">1</property>
</packing>
</child>
+ <child>
+ <placeholder/>
+ </child>
</object>
</child>
<child type="label">
--
1.8.1.2
11 years, 1 month
[PATCH] Set word wrapping on the label telling you how to switch layouts (#924885).
by Chris Lumens
In German, that sentence can be very, very long.
---
pyanaconda/ui/gui/spokes/keyboard.glade | 1 +
1 file changed, 1 insertion(+)
diff --git a/pyanaconda/ui/gui/spokes/keyboard.glade b/pyanaconda/ui/gui/spokes/keyboard.glade
index d48c1c9..3008f44 100644
--- a/pyanaconda/ui/gui/spokes/keyboard.glade
+++ b/pyanaconda/ui/gui/spokes/keyboard.glade
@@ -493,6 +493,7 @@
<property name="halign">end</property>
<property name="valign">start</property>
<property name="label" translatable="yes">Alt + Shift to switch layouts.</property>
+ <property name="wrap">True</property>
<attributes>
<attribute name="font-desc" value="Cantarell Italic 10"/>
<attribute name="style" value="italic"/>
--
1.8.1.2
11 years, 1 month
[PATCH] gtk_thread_wait -> gtk_action_wait in custom.py (#926926).
by Chris Lumens
---
pyanaconda/ui/gui/spokes/custom.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index f9e941d..defaba7 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -80,7 +80,7 @@ from pyanaconda.ui.gui.spokes.lib.passphrase import PassphraseDialog
from pyanaconda.ui.gui.spokes.lib.accordion import *
from pyanaconda.ui.gui.spokes.lib.refresh import RefreshDialog
from pyanaconda.ui.gui.spokes.lib.summary import ActionSummaryDialog
-from pyanaconda.ui.gui.utils import setViewportBackground, gtk_thread_wait
+from pyanaconda.ui.gui.utils import setViewportBackground, gtk_action_wait
from pyanaconda.ui.gui.categories.storage import StorageCategory
from gi.repository import Gtk
@@ -525,7 +525,7 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
threadMgr.add(AnacondaThread(name=THREAD_CUSTOM_STORAGE_INIT, target=self._initialize))
def _initialize(self):
- @gtk_thread_wait
+ @gtk_action_wait
def gtk_action(name):
self.fsCombo.append_text(name)
--
1.8.1.2
11 years, 1 month
[PATCH] Support multiple values for kicstart network --namserver= in dracut (#917481)
by Radek Vykydal
---
dracut/parse-kickstart | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dracut/parse-kickstart b/dracut/parse-kickstart
index 45364c6..d81bdcd 100755
--- a/dracut/parse-kickstart
+++ b/dracut/parse-kickstart
@@ -304,7 +304,8 @@ def ksnet_to_ifcfg(net, filename=None):
if net.mtu:
ifcfg['MTU'] = net.mtu
if net.nameserver:
- ifcfg['DNS1'] = net.nameserver
+ for i, ip in enumerate(net.nameserver.split(",")):
+ ifcfg["DNS%d" % i+1] = ip
if net.nodefroute:
ifcfg['DEFROUTE'] = "no"
--
1.7.11.7
11 years, 1 month
[PATCH] Network spoke: fix model access thinko in Add device dialog
by Radek Vykydal
---
pyanaconda/ui/gui/spokes/network.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
index bca4b19..ec5e076 100644
--- a/pyanaconda/ui/gui/spokes/network.py
+++ b/pyanaconda/ui/gui/spokes/network.py
@@ -511,7 +511,7 @@ class NetworkControlBox(object):
if rc == 1:
ai = self.builder.get_object("combobox_add_device").get_active_iter()
model = self.builder.get_object("liststore_add_device")
- dev_type = model.get[ai][1][0]
+ dev_type = model[ai][1][0]
self.add_device(dev_type)
def add_device(self, type):
--
1.7.11.7
11 years, 1 month