[master:blivet] Get rid of partedFlags field.
by Anne Mulhern
It is unused, and it looks like its last use was removed in anaconda commit
b6427940cfd2de348e70f86d729e1812a46d45e5.
Signed-off-by: mulhern <amulhern(a)redhat.com>
---
blivet/devices.py | 1 -
1 file changed, 1 deletion(-)
diff --git a/blivet/devices.py b/blivet/devices.py
index c3da7f6..a0f8f56 100644
--- a/blivet/devices.py
+++ b/blivet/devices.py
@@ -1325,7 +1325,6 @@ class PartitionDevice(StorageDevice):
# FIXME: Validate partType, but only if this is a new partition
# Otherwise, overwrite it with the partition's type.
self._partType = None
- self.partedFlags = {}
self._partedPartition = None
self._origPath = None
self._currentSize = 0
--
1.9.3
9 years, 11 months
[anaconda][master][PATCH] Add NetworkManager-wifi dependency
by Martin Kolman
IIRC, adding this dependency before broke images but the issue
was resolved, so now is the time to add the dependency again.
Adding only to the GUI subpackage for now as the kickstart support for wifi configuration
seems to be currently broken (will investigate).
Also, there are other NM subpackages we might want to add (3G, ADSL, VPN, etc.)
but the best course of action for them likely is to wait for people to request
a package rather than adding them all.
Martin Kolman (1):
Add NetworkManager-wifi dependency for the GUI subpackage (#1111417)
anaconda.spec.in | 1 +
1 file changed, 1 insertion(+)
--
1.9.3
9 years, 11 months
[PATCH rhel7-branch] Don't change langpacks config of installer environment (#1066017)
by Radek Vykydal
Also copy the configuration to target system.
Resolves: rhbz#1066017
---
pyanaconda/packaging/yumpayload.py | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
index 211e5e9..0b7ec0d 100644
--- a/pyanaconda/packaging/yumpayload.py
+++ b/pyanaconda/packaging/yumpayload.py
@@ -119,6 +119,8 @@ class YumLock(object):
_yum_lock = YumLock()
_yum_cache_dir = "/tmp/yum.cache"
+_yum_installer_langpack_conf = "/tmp/yum.pluginconf.d/langpacks.conf"
+_yum_target_langpack_conf = "/etc/yum/pluginconf.d/langpacks.conf"
class YumPayload(PackagePayload):
""" A YumPayload installs packages onto the target system using yum.
@@ -244,10 +246,17 @@ class YumPayload(PackagePayload):
def _writeLangpacksConfig(self):
langs = [self.data.lang.lang] + self.data.lang.addsupport
log.debug("configuring langpacks for %s" % langs)
- with open("/etc/yum/pluginconf.d/langpacks.conf", "a") as f:
+ iutil.mkdirChain(os.path.dirname(_yum_installer_langpack_conf))
+ shutil.copy2(_yum_target_langpack_conf,
+ _yum_installer_langpack_conf)
+ with open(_yum_installer_langpack_conf, "a") as f:
f.write("# Added by Anaconda\n")
f.write("langpack_locales = %s\n" % ", ".join(langs))
+ def _copyLangpacksConfigToTarget(self):
+ shutil.copy2(_yum_installer_langpack_conf,
+ ROOT_PATH+_yum_target_langpack_conf)
+
def _writeYumConfig(self):
""" Write out anaconda's main yum configuration file. """
buf = """
@@ -257,12 +266,13 @@ keepcache=0
logfile=/tmp/yum.log
metadata_expire=never
pluginpath=/usr/lib/yum-plugins,/tmp/updates/yum-plugins
-pluginconfpath=/etc/yum/pluginconf.d,/tmp/updates/pluginconf.d
+pluginconfpath=%s,/etc/yum/pluginconf.d,/tmp/updates/pluginconf.d
plugins=1
debuglevel=3
errorlevel=6
reposdir=%s
-""" % (_yum_cache_dir, self._repos_dir)
+""" % (_yum_cache_dir, os.path.dirname(_yum_installer_langpack_conf),
+ self._repos_dir)
if flags.noverifyssl:
buf += "sslverify=0\n"
@@ -1739,6 +1749,7 @@ reposdir=%s
self._removeTxSaveFile()
self.writeMultiLibConfig()
+ self._copyLangpacksConfigToTarget()
super(YumPayload, self).postInstall()
--
1.9.0
9 years, 11 months
[PATCH] Write the grub config even on errors (#1114774)
by Brian C. Lane
It can be useful for advanced users to have the config file written even
if bootloader installation failed. This puts the configuration write
into a finally block so that it will be written even when there is
an error.
---
pyanaconda/bootloader.py | 30 +++++++++++++++++-------------
1 file changed, 17 insertions(+), 13 deletions(-)
diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
index eb8bede..509796e 100644
--- a/pyanaconda/bootloader.py
+++ b/pyanaconda/bootloader.py
@@ -1604,15 +1604,17 @@ class GRUB2(GRUB):
self.update()
return
- self.write_device_map()
- self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
- sync()
- self.install()
- sync()
- self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
- self.write_config()
- sync()
- self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
+ try:
+ self.write_device_map()
+ self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
+ sync()
+ self.install()
+ sync()
+ self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
+ finally:
+ self.write_config()
+ sync()
+ self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
def check(self):
""" When installing to the mbr of a disk grub2 needs enough space
@@ -1752,10 +1754,12 @@ class EFIGRUB(GRUB2):
self.update()
return
- sync()
- self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
- self.install()
- self.write_config()
+ try:
+ sync()
+ self.stage2_device.format.sync(root=iutil.getTargetPhysicalRoot())
+ self.install()
+ finally:
+ self.write_config()
def check(self):
return True
--
1.9.3
9 years, 11 months
[lorax] Don't remove usr/lib/rpm/platform/ (#1116450)
by Brian C. Lane
This appears to cause the rpm-plugin-selinux to fail and some of the
selinux lebels aren't applied correctly.
---
share/runtime-cleanup.tmpl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/share/runtime-cleanup.tmpl b/share/runtime-cleanup.tmpl
index 588ce35..c3e9a13 100644
--- a/share/runtime-cleanup.tmpl
+++ b/share/runtime-cleanup.tmpl
@@ -299,7 +299,7 @@ removefrom python-ethtool /usr/sbin/*
removefrom python-meh /usr/share/locale/*
removefrom readline /usr/${libdir}/*
removefrom libreport /usr/bin/* /usr/share/locale/*
-removefrom rpm /usr/bin/* /usr/lib/rpm/platform/* /usr/share/locale/*
+removefrom rpm /usr/bin/* /usr/share/locale/*
removefrom rsync /etc/*
removefrom sed /usr/share/locale/*
removefrom smartmontools /etc/* /usr/sbin/smartd
--
1.9.3
9 years, 11 months
[lorax 1/2] Add kexec anaconda addon (#1115914)
by Brian C. Lane
---
share/runtime-install.tmpl | 1 +
1 file changed, 1 insertion(+)
diff --git a/share/runtime-install.tmpl b/share/runtime-install.tmpl
index e66f9a9..8a25764 100644
--- a/share/runtime-install.tmpl
+++ b/share/runtime-install.tmpl
@@ -3,6 +3,7 @@
## anaconda package
installpkg anaconda anaconda-widgets
+installpkg kexec-tools-anaconda-addon
## anaconda deps that aren't in the RPM
installpkg tmux
installpkg iscsi-initiator-utils
--
1.9.3
9 years, 11 months
[PATCH] postinstall: Reset /etc/resolv.conf to regular file instead of networkd link
by Colin Walters
In:
http://cgit.freedesktop.org/systemd/systemd/commit/?id=d4c6d50a2adfe61c21...
systemd started creating /etc/resolv.conf as a symlink to
../run/systemd/resolve/resolv.conf,
assuming systemd-resolved is in use. Since ../run isn't mounted and
started
in the lorax generated tree, appending to it fails.
Now this is a messy topic as presently lorax-generated systems use
NetworkManager, which does its own handling of resolv.conf. Since NM
wants it to be a plain file, let's set it up that way.
---
share/runtime-postinstall.tmpl | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/share/runtime-postinstall.tmpl
b/share/runtime-postinstall.tmpl
index 4db5756..12638c2 100644
--- a/share/runtime-postinstall.tmpl
+++ b/share/runtime-postinstall.tmpl
@@ -45,8 +45,15 @@ replace "#ReserveVT=6" "ReserveVT=2"
etc/systemd/logind.conf
## Don't write the journal to the overlay, just keep it in RAM
remove var/log/journal
-## install some basic configuration files
+## resolv.conf
+# systemd-resolved may have set up /etc/resolv.conf -> /run/,
+# which we don't want here. Assume for now lorax generated
+# systems will use NetworkManager, or at least be happy
+# with a regular file for /etc/resolv.conf
+remove etc/resolv.conf
append etc/resolv.conf ""
+
+## install some basic configuration files
append etc/fstab ""
install ${configdir}/i18n etc/sysconfig
install ${configdir}/rsyslog.conf etc
--
1.8.3.1
9 years, 11 months
[PATCH 0/3] Update icon names
by David Shea
Surprise! Everything is different!
I'd like to add a test to catch invalid icons used in the python code (and
maybe, Xenu help us, in the C code), but that's going to be super hard and I
figured I'd go ahead and address the immediate problems.
The test for whether an icon exists in the icon theme depends on the
gnome-icon-theme package, so we'll need that in jenkins.
David Shea (3):
Load icons by name instead of stock-id.
Add a check for whether icons used in glade files are valid
Update icon names used within python code.
pyanaconda/ui/gui/helpers.py | 2 +-
pyanaconda/ui/gui/main.glade | 24 ++---
pyanaconda/ui/gui/spokes/advstorage/fcoe.glade | 22 +----
pyanaconda/ui/gui/spokes/advstorage/iscsi.glade | 103 +--------------------
pyanaconda/ui/gui/spokes/datetime_spoke.py | 6 +-
pyanaconda/ui/gui/spokes/keyboard.glade | 6 +-
pyanaconda/ui/gui/spokes/lib/cart.glade | 8 +-
.../ui/gui/spokes/lib/custom_storage_helpers.glade | 4 +-
pyanaconda/ui/gui/spokes/lib/dasdfmt.glade | 88 +++++++++---------
pyanaconda/ui/gui/spokes/lib/passphrase.glade | 38 ++++----
pyanaconda/ui/gui/spokes/lib/passphrase.py | 6 +-
pyanaconda/ui/gui/spokes/lib/refresh.glade | 16 +---
pyanaconda/ui/gui/spokes/welcome.glade | 6 +-
tests/glade/icons/check_icons.py | 72 ++++++++++++++
tests/lib/iconcheck.py | 41 ++++++++
15 files changed, 216 insertions(+), 226 deletions(-)
create mode 100755 tests/glade/icons/check_icons.py
create mode 100644 tests/lib/iconcheck.py
--
2.0.0
9 years, 11 months
[PATCH] Add a basic test for ostree-based installs.
by Chris Lumens
I'm looking for comments on the attached patch. It allows for running
anaconda in a VM through livemedia-creator to do an ostree-based install.
Right now there is no verification of anything about contents of the installed
system - it's assumed that a completed install is good enough. It also
doesn't do a very good job of cleanup. Here's what I'm wondering:
(1) Is there some additional way that I should verify success besides just
whether the installation completed? For instance, should I check for
certain files on the finished system?
(2) Are there other aspects of ostree+anaconda that need to be tested?
(3) I'm building up a collection of tests that require being root to run
(this, storage, GUI). Perhaps there's some better way to iterate through
all the root-only tests than just calling them individually?
- Chris
9 years, 11 months
[PATCH] network: Replace systemd resolv.conf link with regular file
by Colin Walters
[not tested yet, just got done with lorax build]
We want to propagate our network configuration here, so unlink
systemd's link to /run.
---
pyanaconda/network.py | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/pyanaconda/network.py b/pyanaconda/network.py
index 9d589bd..396a029 100644
--- a/pyanaconda/network.py
+++ b/pyanaconda/network.py
@@ -1033,6 +1033,10 @@ def write_network_config(storage, ksdata,
instClass, rootpath):
disableIPV6(rootpath)
copyIfcfgFiles(rootpath)
copyDhclientConfFiles(rootpath)
+ # systemd may have created it as a symlink to /run, overwrite
+ resolvpath = os.path.join("/etc/resolv.conf"
+ if os.path.islink(resolvpath) and not os.path.exists(resolvpath):
+ os.unlink(resolvpath)
copyFileToPath("/etc/resolv.conf", rootpath,
overwrite=flags.livecdInstall)
instClass.setNetworkOnbootDefault(ksdata)
# NM_CONTROLLED is not mirrored in ksdata
--
1.8.3.1
9 years, 11 months