!27 LTS anaconda update 33.19
Merge pull request !27 from hanzj0122/openEuler-20.03-LTS
This commit is contained in:
commit
18e65013db
29
Fix-hiding-of-network-device-activation-switch.patch
Normal file
29
Fix-hiding-of-network-device-activation-switch.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From 3216e5fc1c39354e66c977f76465303ea2a11859 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 16:45:27 +0800
|
||||
Subject: [PATCH] Fix hiding of network device activation switch
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/network.py | 6 ++++--
|
||||
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
|
||||
index d6c1e4b..1318e17 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/network.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/network.py
|
||||
@@ -1019,8 +1019,10 @@ class NetworkControlBox(GObject.GObject):
|
||||
|
||||
switch = self.builder.get_object("device_%s_off_switch" % dev_type_str)
|
||||
if dev_type_str == "wired":
|
||||
- switch.set_visible(state not in (NM.DeviceState.UNAVAILABLE,
|
||||
- NM.DeviceState.UNMANAGED))
|
||||
+ visible = state not in (NM.DeviceState.UNAVAILABLE, NM.DeviceState.UNMANAGED)
|
||||
+ switch.set_visible(visible)
|
||||
+ if not visible:
|
||||
+ switch.set_no_show_all(True)
|
||||
self._updating_device = True
|
||||
switch.set_active(state not in (NM.DeviceState.UNMANAGED,
|
||||
NM.DeviceState.UNAVAILABLE,
|
||||
--
|
||||
2.23.0
|
||||
|
||||
25
add-boot-options-for-smmu-and-crashkernel.patch
Normal file
25
add-boot-options-for-smmu-and-crashkernel.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From c5a47d3285678f9d9ebbbab3d18946d858513732 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 11:04:30 +0800
|
||||
Subject: [PATCH] add boot options for smmu and crashkernel
|
||||
|
||||
---
|
||||
data/anaconda.conf | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/anaconda.conf b/data/anaconda.conf
|
||||
index 89731f4..e75354d 100644
|
||||
--- a/data/anaconda.conf
|
||||
+++ b/data/anaconda.conf
|
||||
@@ -124,7 +124,7 @@ preserved_arguments =
|
||||
speakup_synth apic noapic apm ide noht acpi video
|
||||
pci nodmraid nompath nomodeset noiswmd fips selinux
|
||||
biosdevname ipv6.disable net.ifnames net.ifnames.prefix
|
||||
- nosmt
|
||||
+ nosmt smmu.bypassdev crashkernel
|
||||
|
||||
|
||||
[Storage]
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,24 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/root_password.py anaconda-29.24.7/pyanaconda/ui/gui/spokes/root_password.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/root_password.py 2019-01-30 20:34:33.200096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/root_password.py 2019-01-31 02:41:53.530096820 -0500
|
||||
@@ -274,7 +274,7 @@
|
||||
self.needs_waiver = False
|
||||
else:
|
||||
if not self._validity_check.result.success:
|
||||
- self.can_go_back = True
|
||||
+ self.can_go_back = False
|
||||
self.needs_waiver = True
|
||||
elif not self._ascii_check.result.success:
|
||||
self.can_go_back = True
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/user.py anaconda-29.24.7/pyanaconda/ui/gui/spokes/user.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/user.py 2019-01-30 20:34:33.200096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/user.py 2019-01-31 02:42:17.751096820 -0500
|
||||
@@ -640,7 +640,7 @@
|
||||
if not self._confirm_check.result.success:
|
||||
self.can_go_back = False
|
||||
if not self._validity_check.result.success:
|
||||
- self.can_go_back = True
|
||||
+ self.can_go_back = False
|
||||
self.needs_waiver = True
|
||||
elif not self._ascii_check.result.success:
|
||||
self.can_go_back = True
|
||||
39
add-passwd-check-policy.patch
Normal file
39
add-passwd-check-policy.patch
Normal file
@ -0,0 +1,39 @@
|
||||
From ebfecf7cdd3ed8cdaf118d3da97518c6f4de5023 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 17:21:09 +0800
|
||||
Subject: [PATCH] add passwd check policy
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/root_password.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/user.py | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/root_password.py b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
index cfb9663..313ba0f 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/root_password.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
@@ -290,7 +290,7 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler)
|
||||
self.needs_waiver = False
|
||||
else:
|
||||
if not self._validity_check.result.success:
|
||||
- self.can_go_back = True
|
||||
+ self.can_go_back = False
|
||||
self.needs_waiver = True
|
||||
elif not self._ascii_check.result.success:
|
||||
self.can_go_back = True
|
||||
diff --git a/pyanaconda/ui/gui/spokes/user.py b/pyanaconda/ui/gui/spokes/user.py
|
||||
index 82fbdc8..29e60cb 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/user.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/user.py
|
||||
@@ -673,7 +673,7 @@ class UserSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler):
|
||||
if not self._confirm_check.result.success:
|
||||
self.can_go_back = False
|
||||
if not self._validity_check.result.success:
|
||||
- self.can_go_back = True
|
||||
+ self.can_go_back = False
|
||||
self.needs_waiver = True
|
||||
elif not self._ascii_check.result.success:
|
||||
self.can_go_back = True
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,7 +1,17 @@
|
||||
diff -Naur anaconda-21.48.22.134-old/data/interactive-defaults.ks anaconda-21.48.22.134/data/interactive-defaults.ks
|
||||
--- anaconda-21.48.22.134-old/data/interactive-defaults.ks 2018-11-03 09:06:09.893000000 -0400
|
||||
+++ anaconda-21.48.22.134/data/interactive-defaults.ks 2018-11-03 09:07:25.449000000 -0400
|
||||
@@ -5,9 +5,9 @@
|
||||
From e8ce5155f21af58e119c61e10895fcb5d8c21995 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 17:00:13 +0800
|
||||
Subject: [PATCH] add passwd policy
|
||||
|
||||
---
|
||||
data/interactive-defaults.ks | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/data/interactive-defaults.ks b/data/interactive-defaults.ks
|
||||
index a906c8c..0177cf9 100644
|
||||
--- a/data/interactive-defaults.ks
|
||||
+++ b/data/interactive-defaults.ks
|
||||
@@ -4,9 +4,9 @@ firstboot --enable
|
||||
|
||||
%anaconda
|
||||
# Default password policies
|
||||
@ -14,3 +24,6 @@ diff -Naur anaconda-21.48.22.134-old/data/interactive-defaults.ks anaconda-21.48
|
||||
# NOTE: This applies only to *fully* interactive installations, partial kickstart
|
||||
# installations use defaults specified in pyanaconda/pwpolicy.py.
|
||||
# Automated kickstart installs simply ignore the password policy as the policy
|
||||
--
|
||||
2.23.0
|
||||
|
||||
Binary file not shown.
BIN
anaconda-33.19.tar.bz2
Normal file
BIN
anaconda-33.19.tar.bz2
Normal file
Binary file not shown.
@ -0,0 +1,127 @@
|
||||
From 4e699fe30da24771b80ff1fe64d7791bcb444f79 Mon Sep 17 00:00:00 2001
|
||||
From: Vendula Poncova <vponcova@redhat.com>
|
||||
Date: Tue, 21 Jul 2020 10:57:00 +0200
|
||||
Subject: [PATCH] Allow to detect devices with the iso9660 file system as
|
||||
optical media
|
||||
|
||||
Test that the DBus method FindOpticalMedia identifies devices with the iso9660 file
|
||||
system as optical media, so it is able to find NVDIMM devices with iso9660.
|
||||
|
||||
The DBus method GetDevicesToIgnore of the NVDIMM module shouldn't return NVDIMM
|
||||
devices with the iso9660 file system. They can be used as an installation source.
|
||||
|
||||
Protect all devices with the iso9660 file system. It will protect, for example, NVDIMM
|
||||
devices with the iso9660 file system that can be used only as an installation source
|
||||
anyway.
|
||||
|
||||
Related: rhbz#1856264
|
||||
---
|
||||
.../modules/storage/devicetree/model.py | 5 ++++
|
||||
pyanaconda/modules/storage/nvdimm/nvdimm.py | 12 ++++++++-
|
||||
.../module_device_tree_test.py | 27 ++++++++++++++++---
|
||||
3 files changed, 39 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/modules/storage/devicetree/model.py b/pyanaconda/modules/storage/devicetree/model.py
|
||||
index 4d0ecdb..cdee5a8 100644
|
||||
--- a/pyanaconda/modules/storage/devicetree/model.py
|
||||
+++ b/pyanaconda/modules/storage/devicetree/model.py
|
||||
@@ -303,6 +303,11 @@ class InstallerStorage(Blivet):
|
||||
# cdroms, involves unmounting which is undesirable (see bug #1671713).
|
||||
protected.extend(dev for dev in self.devicetree.devices if dev.type == "cdrom")
|
||||
|
||||
+ # Protect also all devices with an iso9660 file system. It will protect
|
||||
+ # NVDIMM devices that can be used only as an installation source anyway
|
||||
+ # (see the bug #1856264).
|
||||
+ protected.extend(dev for dev in self.devicetree.devices if dev.format.type == "iso9660")
|
||||
+
|
||||
# Mark the collected devices as protected.
|
||||
for dev in protected:
|
||||
log.debug("Marking device %s as protected.", dev.name)
|
||||
diff --git a/pyanaconda/modules/storage/nvdimm/nvdimm.py b/pyanaconda/modules/storage/nvdimm/nvdimm.py
|
||||
index 0bbcc6e..4476dd1 100644
|
||||
--- a/pyanaconda/modules/storage/nvdimm/nvdimm.py
|
||||
+++ b/pyanaconda/modules/storage/nvdimm/nvdimm.py
|
||||
@@ -21,6 +21,7 @@ import gi
|
||||
gi.require_version("BlockDev", "2.0")
|
||||
from gi.repository import BlockDev as blockdev
|
||||
|
||||
+from blivet import udev
|
||||
from blivet.static_data import nvdimm
|
||||
|
||||
from pykickstart.constants import NVDIMM_ACTION_RECONFIGURE, NVDIMM_ACTION_USE
|
||||
@@ -90,6 +91,9 @@ class NVDIMMModule(KickstartBaseModule):
|
||||
installation, the device(s) must be specified by nvdimm kickstart
|
||||
command. Also, only devices in sector mode are allowed.
|
||||
|
||||
+ Don't ignore devices that have an iso9660 file system. We might
|
||||
+ want to use them as an installation source.
|
||||
+
|
||||
:return: a set of device names
|
||||
"""
|
||||
namespaces_to_use = self.get_namespaces_to_use()
|
||||
@@ -97,7 +101,13 @@ class NVDIMMModule(KickstartBaseModule):
|
||||
devices_to_ignore = set()
|
||||
|
||||
for ns_name, ns_info in nvdimm.namespaces.items():
|
||||
- if ns_info.mode != blockdev.NVDIMMNamespaceMode.SECTOR:
|
||||
+ info = udev.get_device(device_node="/dev/" + ns_info.blockdev)
|
||||
+
|
||||
+ if info and udev.device_get_format(info) == "iso9660":
|
||||
+ log.debug("%s / %s won't be ignored - NVDIMM device has "
|
||||
+ "an iso9660 file system", ns_name, ns_info.blockdev)
|
||||
+ continue
|
||||
+ elif ns_info.mode != blockdev.NVDIMMNamespaceMode.SECTOR:
|
||||
log.debug("%s / %s will be ignored - NVDIMM device is not "
|
||||
"in sector mode", ns_name, ns_info.blockdev)
|
||||
elif ns_name not in namespaces_to_use and ns_info.blockdev not in devices_to_use:
|
||||
diff --git a/tests/nosetests/pyanaconda_tests/module_device_tree_test.py b/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
index 838c70e..5e52843 100644
|
||||
--- a/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
+++ b/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
@@ -24,10 +24,10 @@ from unittest.mock import patch, Mock, PropertyMock
|
||||
from tests.nosetests.pyanaconda_tests import patch_dbus_publish_object, check_task_creation
|
||||
|
||||
from blivet.devices import StorageDevice, DiskDevice, DASDDevice, ZFCPDiskDevice, PartitionDevice, \
|
||||
- LUKSDevice, iScsiDiskDevice, NVDIMMNamespaceDevice, FcoeDiskDevice
|
||||
+ LUKSDevice, iScsiDiskDevice, NVDIMMNamespaceDevice, FcoeDiskDevice, OpticalDevice
|
||||
from blivet.errors import StorageError, FSError
|
||||
from blivet.formats import get_format
|
||||
-from blivet.formats.fs import FS
|
||||
+from blivet.formats.fs import FS, Iso9660FS
|
||||
from blivet.formats.luks import LUKS
|
||||
from blivet.size import Size
|
||||
|
||||
@@ -627,9 +627,28 @@ class DeviceTreeInterfaceTestCase(unittest.TestCase):
|
||||
str(cm.exception), "Failed to unmount dev1 from /path: Fake error."
|
||||
)
|
||||
|
||||
- def find_install_media_test(self):
|
||||
+ @patch.object(Iso9660FS, "check_module")
|
||||
+ def find_install_media_test(self, check_module):
|
||||
"""Test FindInstallMedia."""
|
||||
- self.assertEqual(self.interface.FindOpticalMedia(), [])
|
||||
+ dev1 = OpticalDevice("dev1")
|
||||
+ dev1.size = Size("2 GiB")
|
||||
+ dev1.format = get_format("iso9660")
|
||||
+ dev1.controllable = True
|
||||
+ self._add_device(dev1)
|
||||
+
|
||||
+ dev2 = StorageDevice("dev2")
|
||||
+ dev2.size = Size("2 GiB")
|
||||
+ dev2.format = get_format("iso9660")
|
||||
+ dev2.controllable = True
|
||||
+ self._add_device(dev2)
|
||||
+
|
||||
+ dev3 = StorageDevice("dev3")
|
||||
+ dev3.size = Size("2 GiB")
|
||||
+ dev3.format = get_format("ext4")
|
||||
+ dev3.controllable = True
|
||||
+ self._add_device(dev3)
|
||||
+
|
||||
+ self.assertEqual(self.interface.FindOpticalMedia(), ["dev1", "dev2"])
|
||||
|
||||
@patch.object(FS, "update_size_info")
|
||||
def find_mountable_partitions_test(self, update_size_info):
|
||||
--
|
||||
2.23.0
|
||||
|
||||
642
anaconda-Fix-stage2-as-default-sources.patch
Normal file
642
anaconda-Fix-stage2-as-default-sources.patch
Normal file
@ -0,0 +1,642 @@
|
||||
From 5283a20d41050551b54d6d12960ac28e0e5e1648 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Konecny <jkonecny@redhat.com>
|
||||
Date: Tue, 21 Jul 2020 11:17:40 +0200
|
||||
Subject: [PATCH] Fix stage2 as default sources
|
||||
|
||||
We should prioritize stage2 device as the default source.
|
||||
This is especially needed for DVD ISO because it is booting
|
||||
with inst.stage2 instead and we should use the DVD
|
||||
as the source for the default CDROM.
|
||||
The situation is even worse thanks to the fact that
|
||||
DVD ISOs are using inst.stage2=hd:...
|
||||
|
||||
Find stage2 device and test this device first during
|
||||
the auto-discover feature of CDRom source.
|
||||
|
||||
Resolves: rhbz#1856264
|
||||
---
|
||||
.../modules/payloads/source/cdrom/cdrom.py | 7 +-
|
||||
.../payloads/source/cdrom/cdrom_interface.py | 7 +-
|
||||
.../payloads/source/cdrom/initialization.py | 64 +++-
|
||||
pyanaconda/modules/payloads/source/utils.py | 8 +-
|
||||
.../modules/storage/devicetree/handler.py | 5 +-
|
||||
.../storage/devicetree/handler_interface.py | 5 +-
|
||||
pyanaconda/payload/utils.py | 2 +-
|
||||
.../module_device_tree_test.py | 23 +-
|
||||
.../module_source_cdrom_test.py | 286 ++++++++++++++++--
|
||||
9 files changed, 362 insertions(+), 45 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/modules/payloads/source/cdrom/cdrom.py b/pyanaconda/modules/payloads/source/cdrom/cdrom.py
|
||||
index 93df362..bb751ae 100644
|
||||
--- a/pyanaconda/modules/payloads/source/cdrom/cdrom.py
|
||||
+++ b/pyanaconda/modules/payloads/source/cdrom/cdrom.py
|
||||
@@ -32,7 +32,12 @@ log = get_module_logger(__name__)
|
||||
|
||||
|
||||
class CdromSourceModule(PayloadSourceBase, MountingSourceMixin, RPMSourceMixin):
|
||||
- """The CD-ROM source payload module."""
|
||||
+ """The CD-ROM source payload module.
|
||||
+
|
||||
+ This source will try to automatically detect installation source. First it tries to look only
|
||||
+ stage2 device used to boot the environment then it will use first valid iso9660 media with a
|
||||
+ valid structure.
|
||||
+ """
|
||||
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
diff --git a/pyanaconda/modules/payloads/source/cdrom/cdrom_interface.py b/pyanaconda/modules/payloads/source/cdrom/cdrom_interface.py
|
||||
index 0c5b6d7..74d2f14 100644
|
||||
--- a/pyanaconda/modules/payloads/source/cdrom/cdrom_interface.py
|
||||
+++ b/pyanaconda/modules/payloads/source/cdrom/cdrom_interface.py
|
||||
@@ -25,7 +25,12 @@ from pyanaconda.modules.payloads.source.source_base_interface import PayloadSour
|
||||
|
||||
@dbus_interface(PAYLOAD_SOURCE_CDROM.interface_name)
|
||||
class CdromSourceInterface(PayloadSourceBaseInterface):
|
||||
- """Interface for the payload CD-ROM image source."""
|
||||
+ """Interface for the payload CD-ROM image source.
|
||||
+
|
||||
+ This source will try to automatically detect installation source. First it tries to look only
|
||||
+ stage2 device used to boot the environment then it will use first valid iso9660 media with a
|
||||
+ valid structure.
|
||||
+ """
|
||||
|
||||
def connect_signals(self):
|
||||
super().connect_signals()
|
||||
diff --git a/pyanaconda/modules/payloads/source/cdrom/initialization.py b/pyanaconda/modules/payloads/source/cdrom/initialization.py
|
||||
index a182fcd..7fc38fc 100644
|
||||
--- a/pyanaconda/modules/payloads/source/cdrom/initialization.py
|
||||
+++ b/pyanaconda/modules/payloads/source/cdrom/initialization.py
|
||||
@@ -15,13 +15,15 @@
|
||||
# License and may only be used or replicated with the express permission of
|
||||
# Red Hat, Inc.
|
||||
#
|
||||
+from pyanaconda.core.kernel import kernel_arguments
|
||||
from pyanaconda.modules.common.constants.objects import DEVICE_TREE
|
||||
from pyanaconda.modules.common.constants.services import STORAGE
|
||||
from pyanaconda.modules.common.errors.payload import SourceSetupError
|
||||
-from pyanaconda.modules.payloads.source.mount_tasks import SetUpMountTask
|
||||
from pyanaconda.modules.common.structures.storage import DeviceData
|
||||
-from pyanaconda.payload.utils import mount, unmount, PayloadSetupError
|
||||
+from pyanaconda.modules.payloads.source.mount_tasks import SetUpMountTask
|
||||
from pyanaconda.modules.payloads.source.utils import is_valid_install_disk
|
||||
+from pyanaconda.payload.source.factory import SourceFactory, PayloadSourceTypeUnrecognized
|
||||
+from pyanaconda.payload.utils import mount, unmount, PayloadSetupError
|
||||
|
||||
from pyanaconda.anaconda_loggers import get_module_logger
|
||||
log = get_module_logger(__name__)
|
||||
@@ -37,13 +39,62 @@ class SetUpCdromSourceTask(SetUpMountTask):
|
||||
return "Set up CD-ROM Installation Source"
|
||||
|
||||
def _do_mount(self):
|
||||
- """Run CD-ROM installation source setup."""
|
||||
- log.debug("Trying to detect CD-ROM automatically")
|
||||
+ """Run CD-ROM installation source setup.
|
||||
|
||||
+ Try to discover installation media and mount that. Device used for booting (inst.stage2)
|
||||
+ has a priority.
|
||||
+ """
|
||||
+ log.debug("Trying to detect CD-ROM automatically")
|
||||
device_tree = STORAGE.get_proxy(DEVICE_TREE)
|
||||
+
|
||||
+ device_candidates = self._get_device_candidate_list(device_tree)
|
||||
+ device_name = self._choose_installation_device(device_tree, device_candidates)
|
||||
+
|
||||
+ if not device_name:
|
||||
+ raise SourceSetupError("Found no CD-ROM")
|
||||
+
|
||||
+ return device_name
|
||||
+
|
||||
+ def _get_device_candidate_list(self, device_tree):
|
||||
+ stage2_device = self._probe_stage2_for_cdrom(device_tree)
|
||||
+ device_candidates = device_tree.FindOpticalMedia()
|
||||
+
|
||||
+ if stage2_device in device_candidates:
|
||||
+ device_candidates = [stage2_device] + device_candidates
|
||||
+
|
||||
+ return device_candidates
|
||||
+
|
||||
+ @staticmethod
|
||||
+ def _probe_stage2_for_cdrom(device_tree):
|
||||
+ # TODO: This is temporary method which should be moved closer to the inst.repo logic
|
||||
+ log.debug("Testing if inst.stage2 is a CDROM device")
|
||||
+ stage2_string = kernel_arguments.get("stage2")
|
||||
+
|
||||
+ if not stage2_string:
|
||||
+ return None
|
||||
+
|
||||
+ try:
|
||||
+ source = SourceFactory.parse_repo_cmdline_string(stage2_string)
|
||||
+ except PayloadSourceTypeUnrecognized:
|
||||
+ log.warning("Unknown stage2 method: %s", stage2_string)
|
||||
+ return None
|
||||
+
|
||||
+ # We have HDD here because DVD ISO has inst.stage2=hd:LABEL=....
|
||||
+ # TODO: Let's return back support of inst.cdrom=<device> which should work based on the
|
||||
+ # documentation and use that as inst.stage2 parameter for Pungi
|
||||
+ if not source.is_harddrive:
|
||||
+ log.debug("Stage2 can't be used as source %s", stage2_string)
|
||||
+ return None
|
||||
+
|
||||
+ # We can ignore source.path here because DVD ISOs are not using that.
|
||||
+ stage2_device = device_tree.ResolveDevice(source.partition)
|
||||
+ log.debug("Found possible stage2 default installation source %s", stage2_device)
|
||||
+ return stage2_device
|
||||
+
|
||||
+ def _choose_installation_device(self, device_tree, devices_candidates):
|
||||
device_name = ""
|
||||
|
||||
- for dev_name in device_tree.FindOpticalMedia():
|
||||
+ for dev_name in devices_candidates:
|
||||
try:
|
||||
device_data = DeviceData.from_structure(device_tree.GetDeviceData(dev_name))
|
||||
mount(device_data.path, self._target_mount, "iso9660", "ro")
|
||||
@@ -57,7 +108,4 @@ class SetUpCdromSourceTask(SetUpMountTask):
|
||||
else:
|
||||
unmount(self._target_mount)
|
||||
|
||||
- if not device_name:
|
||||
- raise SourceSetupError("Found no CD-ROM")
|
||||
-
|
||||
return device_name
|
||||
diff --git a/pyanaconda/modules/payloads/source/utils.py b/pyanaconda/modules/payloads/source/utils.py
|
||||
index b9642a9..5030fc5 100644
|
||||
--- a/pyanaconda/modules/payloads/source/utils.py
|
||||
+++ b/pyanaconda/modules/payloads/source/utils.py
|
||||
@@ -84,10 +84,10 @@ def find_and_mount_device(device_spec, mount_point):
|
||||
device_path = "/dev/" + matches[0]
|
||||
|
||||
try:
|
||||
- # FIXME: Add back RO mounting. This was removed because we can't mount one source
|
||||
- # RW and RO at the same time. This source is also mounted by IsoChooser dialog in the
|
||||
- # SourceSpoke.
|
||||
- mount(device_path, mount_point, "auto")
|
||||
+ mount(device=device_path,
|
||||
+ mountpoint=mount_point,
|
||||
+ fstype="auto",
|
||||
+ options="defaults,ro")
|
||||
return True
|
||||
except OSError as e:
|
||||
log.error("Mount of device failed: %s", e)
|
||||
diff --git a/pyanaconda/modules/storage/devicetree/handler.py b/pyanaconda/modules/storage/devicetree/handler.py
|
||||
index 1fca6c0..453f27d 100644
|
||||
--- a/pyanaconda/modules/storage/devicetree/handler.py
|
||||
+++ b/pyanaconda/modules/storage/devicetree/handler.py
|
||||
@@ -82,16 +82,17 @@ class DeviceTreeHandler(ABC):
|
||||
msg = "Failed to tear down {}: {}".format(device_name, str(e))
|
||||
raise DeviceSetupError(msg) from None
|
||||
|
||||
- def mount_device(self, device_name, mount_point):
|
||||
+ def mount_device(self, device_name, mount_point, options):
|
||||
"""Mount a filesystem on the device.
|
||||
|
||||
:param device_name: a name of the device
|
||||
:param mount_point: a path to the mount point
|
||||
+ :param options: a string with mount options or an empty string to use defaults
|
||||
:raise: MountFilesystemError if mount fails
|
||||
"""
|
||||
device = self._get_device(device_name)
|
||||
try:
|
||||
- device.format.mount(mountpoint=mount_point)
|
||||
+ device.format.mount(mountpoint=mount_point, options=options or None)
|
||||
except FSError as e:
|
||||
msg = "Failed to mount {} at {}: {}". format(
|
||||
device_name,
|
||||
diff --git a/pyanaconda/modules/storage/devicetree/handler_interface.py b/pyanaconda/modules/storage/devicetree/handler_interface.py
|
||||
index 3839e17..2a16eb7 100644
|
||||
--- a/pyanaconda/modules/storage/devicetree/handler_interface.py
|
||||
+++ b/pyanaconda/modules/storage/devicetree/handler_interface.py
|
||||
@@ -46,14 +46,15 @@ class DeviceTreeHandlerInterface(InterfaceTemplate):
|
||||
"""
|
||||
self.implementation.teardown_device(device_name)
|
||||
|
||||
- def MountDevice(self, device_name: Str, mount_point: Str):
|
||||
+ def MountDevice(self, device_name: Str, mount_point: Str, options: Str):
|
||||
"""Mount a filesystem on the device.
|
||||
|
||||
:param device_name: a name of the device
|
||||
:param mount_point: a path to the mount point
|
||||
+ :param options: a string with mount options or an empty string to use defaults
|
||||
:raise: MountFilesystemError if mount fails
|
||||
"""
|
||||
- self.implementation.mount_device(device_name, mount_point)
|
||||
+ self.implementation.mount_device(device_name, mount_point, options)
|
||||
|
||||
def UnmountDevice(self, device_name: Str, mount_point: Str):
|
||||
"""Unmount a filesystem on the device.
|
||||
diff --git a/pyanaconda/payload/utils.py b/pyanaconda/payload/utils.py
|
||||
index e0c7d6c..eb94f79 100644
|
||||
--- a/pyanaconda/payload/utils.py
|
||||
+++ b/pyanaconda/payload/utils.py
|
||||
@@ -71,7 +71,7 @@ def mount_device(device_name, mount_point):
|
||||
:param str mount_point: a path to the mount point
|
||||
"""
|
||||
device_tree = STORAGE.get_proxy(DEVICE_TREE)
|
||||
- device_tree.MountDevice(device_name, mount_point)
|
||||
+ device_tree.MountDevice(device_name, mount_point, "ro")
|
||||
|
||||
|
||||
def unmount_device(device_name, mount_point):
|
||||
diff --git a/tests/nosetests/pyanaconda_tests/module_device_tree_test.py b/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
index 33b06e8..838c70e 100644
|
||||
--- a/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
+++ b/tests/nosetests/pyanaconda_tests/module_device_tree_test.py
|
||||
@@ -582,12 +582,29 @@ class DeviceTreeInterfaceTestCase(unittest.TestCase):
|
||||
self._add_device(StorageDevice("dev1", fmt=get_format("ext4")))
|
||||
|
||||
with tempfile.TemporaryDirectory() as d:
|
||||
- self.interface.MountDevice("dev1", d)
|
||||
- mount.assert_called_once_with(mountpoint=d)
|
||||
+ self.interface.MountDevice("dev1", d, "")
|
||||
+ mount.assert_called_once_with(mountpoint=d, options=None)
|
||||
|
||||
mount.side_effect = FSError("Fake error.")
|
||||
with self.assertRaises(MountFilesystemError) as cm:
|
||||
- self.interface.MountDevice("dev1", "/path")
|
||||
+ self.interface.MountDevice("dev1", "/path", "")
|
||||
+
|
||||
+ self.assertEqual(
|
||||
+ str(cm.exception), "Failed to mount dev1 at /path: Fake error."
|
||||
+ )
|
||||
+
|
||||
+ @patch.object(FS, "mount")
|
||||
+ def mount_device_with_options_test(self, mount):
|
||||
+ """Test MountDevice with options specified."""
|
||||
+ self._add_device(StorageDevice("dev1", fmt=get_format("ext4")))
|
||||
+
|
||||
+ with tempfile.TemporaryDirectory() as d:
|
||||
+ self.interface.MountDevice("dev1", d, "ro,auto")
|
||||
+ mount.assert_called_once_with(mountpoint=d, options="ro,auto")
|
||||
+
|
||||
+ mount.side_effect = FSError("Fake error.")
|
||||
+ with self.assertRaises(MountFilesystemError) as cm:
|
||||
+ self.interface.MountDevice("dev1", "/path", "ro,auto")
|
||||
|
||||
self.assertEqual(
|
||||
str(cm.exception), "Failed to mount dev1 at /path: Fake error."
|
||||
diff --git a/tests/nosetests/pyanaconda_tests/module_source_cdrom_test.py b/tests/nosetests/pyanaconda_tests/module_source_cdrom_test.py
|
||||
index 386322d..4c964a7 100644
|
||||
--- a/tests/nosetests/pyanaconda_tests/module_source_cdrom_test.py
|
||||
+++ b/tests/nosetests/pyanaconda_tests/module_source_cdrom_test.py
|
||||
@@ -124,6 +124,8 @@ class CdromSourceTestCase(unittest.TestCase):
|
||||
|
||||
class CdromSourceSetupTaskTestCase(unittest.TestCase):
|
||||
|
||||
+ # TODO: To avoid so much patching it would be great to split tests to parts and test those
|
||||
+
|
||||
mount_location = "/mnt/put-cdrom-here"
|
||||
|
||||
def setup_install_source_task_name_test(self):
|
||||
@@ -156,8 +158,15 @@ class CdromSourceSetupTaskTestCase(unittest.TestCase):
|
||||
device_tree.FindOpticalMedia = Mock()
|
||||
device_tree.FindOpticalMedia.return_value = [dev.name for dev in devices]
|
||||
|
||||
+ def _find_device_by_name(name):
|
||||
+ for dev in devices:
|
||||
+ if dev.name == name:
|
||||
+ return DeviceData.to_structure(dev)
|
||||
+
|
||||
+ return None
|
||||
+
|
||||
device_tree.GetDeviceData = Mock()
|
||||
- device_tree.GetDeviceData.side_effect = [DeviceData.to_structure(dev) for dev in devices]
|
||||
+ device_tree.GetDeviceData.side_effect = _find_device_by_name
|
||||
|
||||
return device_tree
|
||||
|
||||
@@ -172,42 +181,261 @@ class CdromSourceSetupTaskTestCase(unittest.TestCase):
|
||||
This matches the logic in tested method.
|
||||
"""
|
||||
for n in range(num_called):
|
||||
- self.assertIn(
|
||||
- call("test{}".format(n)),
|
||||
- device_tree_mock.GetDeviceData.mock_calls
|
||||
- )
|
||||
- self.assertIn(
|
||||
- call("/dev/cdrom-test{}".format(n), self.mount_location, "iso9660", "ro"),
|
||||
- mount_mock.mock_calls
|
||||
- )
|
||||
+ self._check_if_device_was_tried(device_tree_mock,
|
||||
+ mount_mock,
|
||||
+ "test{}".format(n))
|
||||
|
||||
for n in range(num_called, num_called + num_untouched):
|
||||
- self.assertNotIn(
|
||||
- call("test{}".format(n)),
|
||||
- device_tree_mock.GetDeviceData.mock_calls
|
||||
- )
|
||||
- self.assertNotIn(
|
||||
- call("/dev/cdrom-test{}".format(n), self.mount_location, "iso9660", "ro"),
|
||||
- mount_mock.mock_calls
|
||||
- )
|
||||
+ self._check_if_device_was_not_tried(device_tree_mock,
|
||||
+ mount_mock,
|
||||
+ "test{}".format(n))
|
||||
|
||||
self.assertEqual(device_tree_mock.GetDeviceData.call_count, num_called)
|
||||
self.assertEqual(mount_mock.call_count, num_called)
|
||||
|
||||
+ def _check_if_device_was_tried(self,
|
||||
+ device_tree_mock,
|
||||
+ mount_mock,
|
||||
+ device_name):
|
||||
+ self.assertIn(
|
||||
+ call(device_name),
|
||||
+ device_tree_mock.GetDeviceData.mock_calls
|
||||
+ )
|
||||
+
|
||||
+ self.assertIn(
|
||||
+ call("/dev/cdrom-{}".format(device_name), self.mount_location, "iso9660", "ro"),
|
||||
+ mount_mock.mock_calls
|
||||
+ )
|
||||
+
|
||||
+ def _check_if_device_was_not_tried(self,
|
||||
+ device_tree_mock,
|
||||
+ mount_mock,
|
||||
+ device_name):
|
||||
+ self.assertNotIn(
|
||||
+ call(device_name),
|
||||
+ device_tree_mock.GetDeviceData.mock_calls
|
||||
+ )
|
||||
+
|
||||
+ self.assertNotIn(
|
||||
+ call("/dev/cdrom-{}".format(device_name), self.mount_location, "iso9660", "ro"),
|
||||
+ mount_mock.mock_calls
|
||||
+ )
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
+ @patch_dbus_get_proxy
|
||||
+ def priority_stage2_cdrom_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
+ """Test CD-ROM Source setup installation source task run - prioritize inst.stage2 CD-ROMs.
|
||||
+
|
||||
+ Add valid stage2 CDROM device and it has to be tested first.
|
||||
+ """
|
||||
+ kernel_arguments_mock.get.return_value = "hd:LABEL=my-cool-dvd"
|
||||
+ device_tree = self.set_up_device_tree(2)
|
||||
+ device_tree.ResolveDevice.return_value = "test1"
|
||||
+ proxy_getter.return_value = device_tree
|
||||
+ valid_mock.return_value = True
|
||||
+
|
||||
+ task = SetUpCdromSourceTask(self.mount_location)
|
||||
+ result = task.run()
|
||||
+
|
||||
+ # Only one device was checked
|
||||
+ device_tree.ResolveDevice.assert_called_once_with("LABEL=my-cool-dvd")
|
||||
+
|
||||
+ self._check_if_device_was_tried(device_tree, mount_mock, "test1")
|
||||
+ self._check_if_device_was_not_tried(device_tree, mount_mock, "test0")
|
||||
+
|
||||
+ # First device (stage2 device) is valid one
|
||||
+ valid_mock.assert_called_once()
|
||||
+
|
||||
+ # First device works so no unmount is called here
|
||||
+ unmount_mock.assert_not_called()
|
||||
+
|
||||
+ # Test device name returned
|
||||
+ self.assertEqual(result, "test1")
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
+ @patch_dbus_get_proxy
|
||||
+ def priority_stage2_unrecognized_source_cdrom_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
+ """Test CD-ROM Source setup installation source task run - unrecognized stage2 source.
|
||||
+
|
||||
+ This should not happen but when we have the code there let's check it.
|
||||
+ """
|
||||
+ kernel_arguments_mock.get.return_value = "wrong source!"
|
||||
+ device_tree = self.set_up_device_tree(1)
|
||||
+ proxy_getter.return_value = device_tree
|
||||
+ valid_mock.return_value = True
|
||||
+
|
||||
+ task = SetUpCdromSourceTask(self.mount_location)
|
||||
+ result = task.run()
|
||||
+
|
||||
+ device_tree.ResolveDevice.assert_not_called()
|
||||
+
|
||||
+ # 1/2 devices tried, 1/2 untried
|
||||
+ self.assert_resolve_and_mount_calls(device_tree, mount_mock, 1, 1)
|
||||
+
|
||||
+ # Only first was mounted
|
||||
+ self.assertEqual(valid_mock.call_count, 1)
|
||||
+
|
||||
+ # First device was used no unmount should be called
|
||||
+ unmount_mock.assert_not_called()
|
||||
+
|
||||
+ # Test device name returned
|
||||
+ self.assertEqual(result, "test0")
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
+ @patch_dbus_get_proxy
|
||||
+ def priority_stage2_not_hdd_source_cdrom_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
+ """Test CD-ROM Source setup installation source task run - stage2 is not HDD source.
|
||||
+
|
||||
+ We are testing HDD because DVD ISOs are created with inst.stage2=hd: . We want to change
|
||||
+ this behavior on master so let's change this test too then.
|
||||
+
|
||||
+ TODO: Change this test when DVD ISOs will use cdrom:<device> instead of inst.stage2=hd:...
|
||||
+ """
|
||||
+ kernel_arguments_mock.get.return_value = "nfs:test.org:/super/cool/path"
|
||||
+ device_tree = self.set_up_device_tree(1)
|
||||
+ proxy_getter.return_value = device_tree
|
||||
+ valid_mock.return_value = True
|
||||
+
|
||||
+ task = SetUpCdromSourceTask(self.mount_location)
|
||||
+ result = task.run()
|
||||
+
|
||||
+ device_tree.ResolveDevice.assert_not_called()
|
||||
+
|
||||
+ # 1/2 devices tried, 1/2 untried
|
||||
+ self.assert_resolve_and_mount_calls(device_tree, mount_mock, 1, 1)
|
||||
+
|
||||
+ # Only first was mounted
|
||||
+ self.assertEqual(valid_mock.call_count, 1)
|
||||
+
|
||||
+ # First device was used no unmount should be called
|
||||
+ unmount_mock.assert_not_called()
|
||||
+
|
||||
+ # Test device name returned
|
||||
+ self.assertEqual(result, "test0")
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
@patch_dbus_get_proxy
|
||||
- def choose_from_multiple_cdroms_test(self, proxy_getter, mount_mock, unmount_mock, valid_mock):
|
||||
+ def priority_stage2_cant_be_resolved_source_cdrom_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
+ """Test CD-ROM Source setup installation source task run - can't resolve stage2 device.
|
||||
+
|
||||
+ Stage2 device can't be resolved. This should not happen but let's make sure the code works.
|
||||
+ """
|
||||
+ kernel_arguments_mock.get.return_value = "hd:LABEL=my-cool-dvd"
|
||||
+ device_tree = self.set_up_device_tree(1)
|
||||
+ proxy_getter.return_value = device_tree
|
||||
+ # When device can't be resolved it returns an empty string.
|
||||
+ device_tree.ResolveDevice.return_value = ""
|
||||
+ valid_mock.return_value = True
|
||||
+
|
||||
+ task = SetUpCdromSourceTask(self.mount_location)
|
||||
+ result = task.run()
|
||||
+
|
||||
+ self._check_if_device_was_not_tried(device_tree, mount_mock, "")
|
||||
+
|
||||
+ # 1/2 devices tried, 1/2 untried
|
||||
+ self.assert_resolve_and_mount_calls(device_tree, mount_mock, 1, 1)
|
||||
+
|
||||
+ # Only first was mounted
|
||||
+ self.assertEqual(valid_mock.call_count, 1)
|
||||
+
|
||||
+ # First device was used no unmount should be called
|
||||
+ unmount_mock.assert_not_called()
|
||||
+
|
||||
+ # Test device name returned
|
||||
+ self.assertEqual(result, "test0")
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
+ @patch_dbus_get_proxy
|
||||
+ def priority_stage2_not_optical_media_cdrom_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
+ """Test CD-ROM Source setup installation source task run - stage2 is not optical media.
|
||||
+
|
||||
+ We should not pick stage2 device if it is not an optical_media which means type iso9660.
|
||||
+ """
|
||||
+ kernel_arguments_mock.get.return_value = "hd:LABEL=correct-device"
|
||||
+ device_tree = self.set_up_device_tree(1)
|
||||
+ device_tree.ResolveDevice.return_value = "not-optical-media"
|
||||
+ proxy_getter.return_value = device_tree
|
||||
+ valid_mock.return_value = True
|
||||
+
|
||||
+ task = SetUpCdromSourceTask(self.mount_location)
|
||||
+ result = task.run()
|
||||
+
|
||||
+ device_tree.ResolveDevice.assert_called_once_with("LABEL=correct-device")
|
||||
+
|
||||
+ self._check_if_device_was_not_tried(device_tree, mount_mock, "correct-device")
|
||||
+
|
||||
+ # 1/2 devices tried, 1/2 untried
|
||||
+ self.assert_resolve_and_mount_calls(device_tree, mount_mock, 1, 1)
|
||||
+
|
||||
+ # Only first was mounted
|
||||
+ self.assertEqual(valid_mock.call_count, 1)
|
||||
+
|
||||
+ # First device was used no unmount should be called
|
||||
+ unmount_mock.assert_not_called()
|
||||
+
|
||||
+ # Test device name returned
|
||||
+ self.assertEqual(result, "test0")
|
||||
+
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
+ @patch_dbus_get_proxy
|
||||
+ def choose_from_multiple_cdroms_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
"""Test CD-ROM Source setup installation source task run - choice from multiple CD-ROMs.
|
||||
|
||||
Fake four CD-ROM devices: First fails to mount, second has nothing useful, third has what
|
||||
we want so is left mounted, fourth is entirely skipped.
|
||||
The other two tests below are needed only to test the exit when nothing is found.
|
||||
"""
|
||||
+ kernel_arguments_mock.get.return_value = None
|
||||
device_tree = self.set_up_device_tree(4)
|
||||
proxy_getter.return_value = device_tree
|
||||
-
|
||||
mount_mock.side_effect = \
|
||||
[PayloadSetupError("Mocked failure"), DEFAULT, DEFAULT, DEFAULT]
|
||||
|
||||
@@ -231,18 +459,24 @@ class CdromSourceSetupTaskTestCase(unittest.TestCase):
|
||||
# Test device name returned
|
||||
self.assertEqual(result, "test2")
|
||||
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
@patch_dbus_get_proxy
|
||||
- def failure_to_mount_test(self, proxy_getter, mount_mock, unmount_mock, valid_mock):
|
||||
+ def failure_to_mount_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
"""Test CD-ROM Source setup installation source task run - mount failure.
|
||||
|
||||
Mocks one disk which fails to mount, expect exception.
|
||||
"""
|
||||
+ kernel_arguments_mock.get.return_value = None
|
||||
device_tree = self.set_up_device_tree(1)
|
||||
proxy_getter.return_value = device_tree
|
||||
-
|
||||
mount_mock.side_effect = PayloadSetupError("Mocked failure")
|
||||
valid_mock.return_value = True
|
||||
|
||||
@@ -258,18 +492,24 @@ class CdromSourceSetupTaskTestCase(unittest.TestCase):
|
||||
# exception happened due to no disk
|
||||
self.assertEqual(str(cm.exception), "Found no CD-ROM")
|
||||
|
||||
+ @patch("pyanaconda.modules.payloads.source.cdrom.initialization.kernel_arguments")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.is_valid_install_disk")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.unmount")
|
||||
@patch("pyanaconda.modules.payloads.source.cdrom.initialization.mount")
|
||||
@patch_dbus_get_proxy
|
||||
- def no_cdrom_with_valid_source_test(self, proxy_getter, mount_mock, unmount_mock, valid_mock):
|
||||
+ def no_cdrom_with_valid_source_test(self,
|
||||
+ proxy_getter,
|
||||
+ mount_mock,
|
||||
+ unmount_mock,
|
||||
+ valid_mock,
|
||||
+ kernel_arguments_mock):
|
||||
"""Test CD-ROM Source setup installation source task run - no valid source CD-ROMs.
|
||||
|
||||
Mocks one CD-ROM device which has nothing useful, expect exception.
|
||||
"""
|
||||
+ kernel_arguments_mock.get.return_value = None
|
||||
device_tree = self.set_up_device_tree(1)
|
||||
proxy_getter.return_value = device_tree
|
||||
-
|
||||
valid_mock.return_value = False
|
||||
|
||||
with self.assertRaises(SourceSetupError) as cm:
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,85 +0,0 @@
|
||||
From e39ab9aee03aebda41e4c247e5f3e58f62abb54b Mon Sep 17 00:00:00 2001
|
||||
From: Vendula Poncova <vponcova@redhat.com>
|
||||
Date: Tue, 2 Jun 2020 17:20:19 +0200
|
||||
Subject: [PATCH] Extend the start-module script
|
||||
|
||||
Allow to specify environment variables with the --env options. The environment
|
||||
will be set up before the module is started.
|
||||
|
||||
Examples:
|
||||
|
||||
./start-module pyanaconda.modules.boss
|
||||
./start-module --env LD_PRELOAD=libgomp.so.1 pyanaconda.modules.payloads
|
||||
|
||||
Related: rhbz#1722181
|
||||
|
||||
The environment variable LD_PRELOAD needs to be set up during the start of
|
||||
the Payloads module, but it needs to be dropped after that.
|
||||
|
||||
After the modularization, only the Payloads module should require LD_PRELOAD.
|
||||
|
||||
Related: rhbz#1722181
|
||||
---
|
||||
...g.fedoraproject.Anaconda.Modules.Payload.service | 2 +-
|
||||
pyanaconda/modules/payload/__main__.py | 4 ++++
|
||||
scripts/start-module | 21 +++++++++++++++++++++
|
||||
3 files changed, 26 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/dbus/org.fedoraproject.Anaconda.Modules.Payload.service b/data/dbus/org.fedoraproject.Anaconda.Modules.Payload.service
|
||||
index f6a50c2..a33f87a 100644
|
||||
--- a/data/dbus/org.fedoraproject.Anaconda.Modules.Payload.service
|
||||
+++ b/data/dbus/org.fedoraproject.Anaconda.Modules.Payload.service
|
||||
@@ -1,4 +1,4 @@
|
||||
[D-BUS Service]
|
||||
Name=org.fedoraproject.Anaconda.Modules.Payload
|
||||
-Exec=/usr/libexec/anaconda/start-module pyanaconda.modules.payload
|
||||
+Exec=/usr/libexec/anaconda/start-module --env LD_PRELOAD=libgomp.so.1 pyanaconda.modules.payload
|
||||
User=root
|
||||
diff --git a/pyanaconda/modules/payload/__main__.py b/pyanaconda/modules/payload/__main__.py
|
||||
index 2d53f94..863b151 100644
|
||||
--- a/pyanaconda/modules/payload/__main__.py
|
||||
+++ b/pyanaconda/modules/payload/__main__.py
|
||||
@@ -1,6 +1,10 @@
|
||||
from pyanaconda.modules.common import init
|
||||
init()
|
||||
|
||||
+import os
|
||||
+if "LD_PRELOAD" in os.environ:
|
||||
+ del os.environ["LD_PRELOAD"]
|
||||
+
|
||||
from pyanaconda.modules.payload.payload import PayloadModule
|
||||
payload_module = PayloadModule()
|
||||
payload_module.run()
|
||||
diff --git a/scripts/start-module b/scripts/start-module
|
||||
index 4bc5b0f..6e8da2a 100755
|
||||
--- a/scripts/start-module
|
||||
+++ b/scripts/start-module
|
||||
@@ -1,4 +1,25 @@
|
||||
#!/bin/bash
|
||||
+# Start the Anaconda's Python module $1.
|
||||
+# Examples:
|
||||
+# ./start-module pyanaconda.modules.boss
|
||||
+# ./start-module --env LD_PRELOAD=libgomp.so.1 pyanaconda.modules.payloads
|
||||
+#
|
||||
+
|
||||
+# Process the arguments.
|
||||
+while true
|
||||
+do
|
||||
+ case $1 in
|
||||
+ # Set up the environment.
|
||||
+ --env)
|
||||
+ export $2
|
||||
+ shift 2
|
||||
+ ;;
|
||||
+ # Nothing else to do.
|
||||
+ *)
|
||||
+ break
|
||||
+ ;;
|
||||
+ esac
|
||||
+done
|
||||
|
||||
# add updates & product image directories to PYTHONPATH if
|
||||
# it looks like we are in the installation environment
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,57 +0,0 @@
|
||||
From ff06b13c273bcabd538eec2095d480867166f0fd Mon Sep 17 00:00:00 2001
|
||||
From: Martin Kolman <mkolman@redhat.com>
|
||||
Date: Tue, 29 Oct 2019 14:00:46 +0100
|
||||
Subject: [PATCH] Add a temporary hack to fix installations on ppc64le and
|
||||
aarch64 (#1764666)
|
||||
|
||||
Quoting bug 1764666:
|
||||
|
||||
"Currently Rawhide isn't installable on aarch64 and ppc64le,
|
||||
because we are hitting bug #1722181 again.
|
||||
The reasons are increased size of TLS in current distro
|
||||
(resp. in the libs the python interpreter loads for anaconda to run)
|
||||
combined with internal limitations of TLS support on these platforms.
|
||||
I talked to the toolchain people and they think it can be fixed,
|
||||
but it will take some months before the fix is available.
|
||||
You can read the details in the thread starting with
|
||||
https://sourceware.org/ml/libc-alpha/2019-09/msg00512.html,
|
||||
https://sourceware.org/bugzilla/show_bug.cgi?id=25051
|
||||
is the current plan for a fix.
|
||||
|
||||
So to unblock Rawhide on aarch64 and ppc64le, I propose we carry a patch
|
||||
in the Fedora anaconda rpms, that workarounds the problem. Although the
|
||||
change is harmless, I don't think it belongs to upstream anaconda, thus
|
||||
the request for a patch. I have tested the patch thru an updates image
|
||||
on ppc64le and it makes anaconda run again."
|
||||
|
||||
Unfortunately due to how our release process works, it's easier to
|
||||
temporarily have this patch in upstream rather than to carry it as
|
||||
a downstream patch for Rawhide.
|
||||
|
||||
Resolves: rhbz#1764666
|
||||
Related: rhbz#1722181
|
||||
---
|
||||
data/tmux.conf | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/tmux.conf b/data/tmux.conf
|
||||
index c909aca31..be7c38e3e 100644
|
||||
--- a/data/tmux.conf
|
||||
+++ b/data/tmux.conf
|
||||
@@ -18,7 +18,12 @@ set-option -g history-limit 10000
|
||||
|
||||
# The idea here is to detach the client started here via anaconda.service, and
|
||||
# then re-attach to it in the tmux service run on the console tty.
|
||||
-new-session -d -s anaconda -n main "anaconda"
|
||||
+
|
||||
+# FIXME: Temporary hot fix added to make Fedora installable on aarch64 and ppc64le.
|
||||
+# For more infromation see:
|
||||
+# rhbz#1764666
|
||||
+# rhbz#1722181
|
||||
+new-session -d -s anaconda -n main "LD_PRELOAD=libgomp.so.1 anaconda"
|
||||
|
||||
set-option status-right '#[fg=blue]#(echo -n "Switch tab: Alt+Tab | Help: F1 ")'
|
||||
|
||||
--
|
||||
2.17.1
|
||||
|
||||
@ -1,24 +0,0 @@
|
||||
From a5c305939ac0261c428da982891be2e753b54b4e Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Sat, 11 Jan 2020 17:23:48 +0800
|
||||
Subject: [PATCH] add boot options for raid 3408
|
||||
|
||||
---
|
||||
pyanaconda/bootloader.py | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
|
||||
index e0e93d5..4f96c99 100644
|
||||
--- a/pyanaconda/bootloader.py
|
||||
+++ b/pyanaconda/bootloader.py
|
||||
@@ -1537,6 +1537,7 @@ class GRUB2(GRUB):
|
||||
if blivet.arch.is_aarch64():
|
||||
log.info("check boot args:%s",arg_str)
|
||||
arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
+ arg_str+=" smmu.bypassdev=0x1000:0x17 smmu.bypassdev=0x1000:0x15"
|
||||
else:
|
||||
arg_str+=" quiet"
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,29 +0,0 @@
|
||||
From 10e74d1ae32d7323bea98a3667cae4b995c7a511 Mon Sep 17 00:00:00 2001
|
||||
From: Jialong Chen <chenjialong@huawei.com>
|
||||
Date: Wed, 15 Jan 2020 21:42:36 +0800
|
||||
Subject: [PATCH] add kdump parameter into kernel cmdline
|
||||
|
||||
Signed-off-by: Jialong Chen <chenjialong@huawei.com>
|
||||
---
|
||||
pyanaconda/bootloader.py | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
|
||||
index 4f96c99..5162316 100644
|
||||
--- a/pyanaconda/bootloader.py
|
||||
+++ b/pyanaconda/bootloader.py
|
||||
@@ -1537,9 +1537,9 @@ class GRUB2(GRUB):
|
||||
if blivet.arch.is_aarch64():
|
||||
log.info("check boot args:%s",arg_str)
|
||||
arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
- arg_str+=" smmu.bypassdev=0x1000:0x17 smmu.bypassdev=0x1000:0x15"
|
||||
+ arg_str+=" smmu.bypassdev=0x1000:0x17 smmu.bypassdev=0x1000:0x15 crashkernel=1024M,high"
|
||||
else:
|
||||
- arg_str+=" quiet"
|
||||
+ arg_str+=" quiet crashkernel=512M"
|
||||
|
||||
log.info("bootloader.py: used boot args: %s ", arg_str)
|
||||
defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % arg_str)
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,63 +0,0 @@
|
||||
diff -uNrp a/pyanaconda/installclasses/more_os_name.py b/pyanaconda/installclasses/more_os_name.py
|
||||
--- a/pyanaconda/installclasses/more_os_name.py 1970-01-01 08:00:00.000000000 +0800
|
||||
+++ b/pyanaconda/installclasses/more_os_name.py 2019-08-23 16:42:14.208000000 +0800
|
||||
@@ -0,0 +1,59 @@
|
||||
+#
|
||||
+# more_os_name.py
|
||||
+#
|
||||
+# Copyright (C) 2019. Huawei Technologies Co., Ltd. All rights reserved.
|
||||
+#
|
||||
+# This program is free software; you can redistribute it and/or modify
|
||||
+# it under the terms of the GNU General Public License version 2 and
|
||||
+# only version 2 as published by the Free Software Foundation.
|
||||
+#
|
||||
+# This program is distributed in the hope that it will be useful,
|
||||
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+# GNU General Public License for more details.
|
||||
+#
|
||||
+
|
||||
+from pyanaconda.installclass import BaseInstallClass
|
||||
+from pyanaconda.product import productName
|
||||
+from pyanaconda import network
|
||||
+from pyanaconda import nm
|
||||
+
|
||||
+__all__ = ["more_os_nameBaseInstallClass"]
|
||||
+
|
||||
+
|
||||
+class more_os_nameBaseInstallClass(BaseInstallClass):
|
||||
+ name = "more_os_name Linux"
|
||||
+ sortPriority = 10000
|
||||
+ if not productName.startswith("more_os_name"): # pylint: disable=no-member
|
||||
+ hidden = True
|
||||
+ defaultFS = "ext4"
|
||||
+
|
||||
+ bootloaderTimeoutDefault = 5
|
||||
+
|
||||
+ ignoredPackages = ["ntfsprogs"]
|
||||
+
|
||||
+ installUpdates = False
|
||||
+
|
||||
+ _l10n_domain = "comps"
|
||||
+
|
||||
+ efi_dir = "more_os_name"
|
||||
+
|
||||
+ help_placeholder = ""
|
||||
+ help_placeholder_with_links = ""
|
||||
+
|
||||
+ eula_path = "/usr/share/more_os_name-release/EULA"
|
||||
+
|
||||
+ blivet_gui_supported = False
|
||||
+
|
||||
+ def setNetworkOnbootDefault(self, ksdata):
|
||||
+ if any(nd.onboot for nd in ksdata.network.network if nd.device):
|
||||
+ return
|
||||
+ # choose the device used during installation
|
||||
+ # (ie for majority of cases the one having the default route)
|
||||
+ dev = network.default_route_device() or network.default_route_device(family="inet6")
|
||||
+ if not dev:
|
||||
+ return
|
||||
+ # ignore wireless (its ifcfgs would need to be handled differently)
|
||||
+ if nm.nm_device_type_is_wifi(dev):
|
||||
+ return
|
||||
+ network.update_onboot_value(dev, True, ksdata=ksdata)
|
||||
@ -1,25 +0,0 @@
|
||||
From 2cae8055f3d38e071969039ae96ae4696bf5832d Mon Sep 17 00:00:00 2001
|
||||
From: root <root@localhost.localdomain>
|
||||
Date: Thu, 12 Dec 2019 04:21:48 -0500
|
||||
Subject: [PATCH] add quiet cmdline args for x86
|
||||
|
||||
---
|
||||
pyanaconda/bootloader.py | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
|
||||
index 4d69e31..e0e93d5 100644
|
||||
--- a/pyanaconda/bootloader.py
|
||||
+++ b/pyanaconda/bootloader.py
|
||||
@@ -1537,6 +1537,8 @@ class GRUB2(GRUB):
|
||||
if blivet.arch.is_aarch64():
|
||||
log.info("check boot args:%s",arg_str)
|
||||
arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
+ else:
|
||||
+ arg_str+=" quiet"
|
||||
|
||||
log.info("bootloader.py: used boot args: %s ", arg_str)
|
||||
defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % arg_str)
|
||||
--
|
||||
2.19.1
|
||||
|
||||
@ -1,17 +0,0 @@
|
||||
diff -Nur anaconda-19.31.123-orig/pyanaconda/anaconda_logging.py anaconda-19.31.123/pyanaconda/anaconda_logging.py
|
||||
--- anaconda-19.31.123-orig/pyanaconda/anaconda_logging.py 2017-10-12 21:46:46.936000000 -0400
|
||||
+++ anaconda-19.31.123/pyanaconda/anaconda_logging.py 2017-10-12 21:49:15.310000000 -0400
|
||||
@@ -28,4 +28,5 @@
|
||||
import sys
|
||||
import warnings
|
||||
+import time
|
||||
|
||||
from pyanaconda.flags import flags
|
||||
@@ -187,6 +187,7 @@
|
||||
def __init__(self):
|
||||
self.loglevel = DEFAULT_LEVEL
|
||||
self.remote_syslog = None
|
||||
+ logging.Formatter.converter = time.gmtime
|
||||
# Rename the loglevels so they are the same as in syslog.
|
||||
logging.addLevelName(logging.CRITICAL, "CRT")
|
||||
logging.addLevelName(logging.ERROR, "ERR")
|
||||
@ -1,13 +0,0 @@
|
||||
diff -uNrp a/data/anaconda-gtk.css b/data/anaconda-gtk.css
|
||||
--- a/data/anaconda-gtk.css 2019-08-21 18:50:27.188000000 +0800
|
||||
+++ b/data/anaconda-gtk.css 2019-08-21 18:52:23.172000000 +0800
|
||||
@@ -112,7 +112,8 @@ levelbar.discrete trough block.filled.hi
|
||||
AnacondaSpokeWindow #nav-box {
|
||||
background-color: @fedora;
|
||||
background-image: url('/usr/share/anaconda/pixmaps/topbar-bg.png');
|
||||
- background-repeat: repeat;
|
||||
+ background-repeat: no-repeat;
|
||||
+ background-size: 100% 100%;
|
||||
color: white;
|
||||
}
|
||||
|
||||
@ -1,13 +0,0 @@
|
||||
--- anaconda-29.24.7/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
@@ -1134,6 +1134,9 @@
|
||||
else:
|
||||
return _("Remote directory is required")
|
||||
|
||||
+ if ":" not in url_string or len(url_string.split(":")) != 2:
|
||||
+ return _("Server must be specified as SERVER:/PATH")
|
||||
+
|
||||
return InputCheck.CHECK_OK
|
||||
|
||||
def _checkURLEntry(self, inputcheck):
|
||||
|
||||
@ -1,30 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7.old/po/zh_CN.po anaconda-29.24.7/po/zh_CN.po
|
||||
--- anaconda-29.24.7.old/po/zh_CN.po 2019-01-31 04:13:38.275096820 -0500
|
||||
+++ anaconda-29.24.7/po/zh_CN.po 2019-01-31 04:17:46.997096820 -0500
|
||||
@@ -3795,10 +3795,10 @@
|
||||
#: pyanaconda/network.py:121
|
||||
msgid ""
|
||||
"Host names can only contain the characters 'a-z', 'A-Z', '0-9', '-', or '.',"
|
||||
-" parts between periods must contain something and cannot start or end with "
|
||||
-"'-'."
|
||||
+" parts between periods must contain something being 63 or fewer "
|
||||
+"characters and cannot start or end with '-'."
|
||||
msgstr ""
|
||||
-"主机名只能包含 'a-z', 'A-Z', '0-9', '-'(英文减号), 或者 '.'(英文点号),其中两个点号中不能为空且不能以'-'开头或结尾"
|
||||
+"主机名只能包含 'a-z', 'A-Z', '0-9', '-'(英文减号), 或者 '.'(英文点号),其中两个点号中不能为空,必须少于64个字符且不能以'-'开头或结尾"
|
||||
|
||||
#: pyanaconda/network.py:1664
|
||||
msgid "Connecting..."
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/network.py anaconda-29.24.7/pyanaconda/network.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/network.py 2019-01-31 04:13:38.276096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/network.py 2019-01-31 04:19:17.918096820 -0500
|
||||
@@ -120,8 +120,8 @@
|
||||
if not (re.match('^' + HOSTNAME_PATTERN_WITHOUT_ANCHORS + '$', hostname)):
|
||||
return (False, _("Host names can only contain the characters 'a-z', "
|
||||
"'A-Z', '0-9', '-', or '.', parts between periods "
|
||||
- "must contain something and cannot start or end with "
|
||||
- "'-'."))
|
||||
+ "must contain something being 63 or fewer "
|
||||
+ "characters and cannot start or end with '-'."))
|
||||
|
||||
return (True, "")
|
||||
@ -1,11 +0,0 @@
|
||||
diff -uNrp a/data/anaconda-gtk.css b/data/anaconda-gtk.css
|
||||
--- a/data/anaconda-gtk.css 2018-06-08 05:31:59.000000000 +0800
|
||||
+++ b/data/anaconda-gtk.css 2019-08-12 20:37:52.544000000 +0800
|
||||
@@ -98,6 +98,7 @@ levelbar.discrete trough block.filled.hi
|
||||
.logo {
|
||||
background-image: url('/usr/share/anaconda/pixmaps/sidebar-logo.png');
|
||||
background-position: 50% 20px;
|
||||
+ background-size: 90%;
|
||||
background-repeat: no-repeat;
|
||||
background-color: transparent;
|
||||
}
|
||||
@ -1,12 +0,0 @@
|
||||
--- anaconda-29.24.7/pyanaconda/users.py
|
||||
+++ anaconda-29.24.7/pyanaconda/users.py
|
||||
@@ -397,7 +397,7 @@
|
||||
# Reset sp_lstchg to an empty string. On systems with no rtc, this
|
||||
# field can be set to 0, which has a special meaning that the password
|
||||
# must be reset on the next login.
|
||||
- util.execWithRedirect("chage", ["-R", root, "-d", "", username])
|
||||
+ #util.execWithRedirect("chage", ["-R", root, "-d", "", username])
|
||||
|
||||
def setRootPassword(self, password, isCrypted=False, isLocked=False, algo=None, root="/"):
|
||||
return self.setUserPassword("root", password, isCrypted, isLocked, algo, root)
|
||||
|
||||
@ -1,47 +0,0 @@
|
||||
diff -uNrp a/pyanaconda/ui/gui/hubs/progress.py b/pyanaconda/ui/gui/hubs/progress.py
|
||||
--- a/pyanaconda/ui/gui/hubs/progress.py 2018-07-25 21:58:20.000000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/hubs/progress.py 2019-08-12 21:14:11.720000000 +0800
|
||||
@@ -21,8 +21,9 @@ import gi
|
||||
from pyanaconda.core.timer import Timer
|
||||
|
||||
gi.require_version("Gtk", "3.0")
|
||||
+gi.require_version("GdkPixbuf", "2.0")
|
||||
|
||||
-from gi.repository import Gtk
|
||||
+from gi.repository import Gtk, GdkPixbuf
|
||||
|
||||
import itertools
|
||||
import os
|
||||
@@ -251,6 +252,11 @@ class ProgressHub(Hub):
|
||||
# An infinite list of the page numbers containing ransom notes images.
|
||||
self._rnotesPages = itertools.cycle(range(rnotes_start,
|
||||
self._progressNotebook.get_n_pages()))
|
||||
+
|
||||
+ #resize image when in low resolution
|
||||
+ self._progressNotebook_width = -1
|
||||
+ self._progressNotebook.connect('size_allocate', self.on_allocate, range(rnotes_start,
|
||||
+ self._progressNotebook.get_n_pages()))
|
||||
else:
|
||||
# Add a blank page to the notebook and we'll just cycle to that
|
||||
# over and over again.
|
||||
@@ -295,6 +301,20 @@ class ProgressHub(Hub):
|
||||
|
||||
gtk_call_once(self._progressLabel.set_text, message)
|
||||
|
||||
+ def on_allocate(self, notebook, allocation, page_range):
|
||||
+ request = notebook.get_size_request()
|
||||
+ if allocation.width >= request.width or allocation.width >= self._progressNotebook_width and self._progressNotebook_width != -1:
|
||||
+ return
|
||||
+ self._progressNotebook_width = allocation.width
|
||||
+ for i in page_range:
|
||||
+ widget = notebook.get_nth_page(i)
|
||||
+ image_allocation = widget.get_allocation()
|
||||
+ pixbuf = widget.get_pixbuf()
|
||||
+ if pixbuf.get_width() > image_allocation.width:
|
||||
+ resize_height = image_allocation.width / pixbuf.get_width() * image_allocation.height
|
||||
+ pixbuf = pixbuf.scale_simple(image_allocation.width, resize_height, GdkPixbuf.InterpType.BILINEAR)
|
||||
+ widget.set_from_pixbuf(pixbuf)
|
||||
+
|
||||
@async_action_nowait
|
||||
def _restart_spinner(self):
|
||||
self._spinner.show()
|
||||
@ -1,83 +0,0 @@
|
||||
From e620f323fcbaa45f16b8863d2e0417fb423aea16 Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Thu, 16 Jan 2020 21:41:33 +0800
|
||||
Subject: [PATCH] modify default timezone and zh_CN_po
|
||||
|
||||
---
|
||||
po/zh_CN.po | 2 +-
|
||||
pyanaconda/kickstart.py | 4 ++--
|
||||
pyanaconda/modules/timezone/timezone.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/datetime_spoke.py | 2 +-
|
||||
tests/nosetests/pyanaconda_tests/module_timezone_test.py | 2 +-
|
||||
5 files changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index c492042..cf59d45 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -4193,7 +4193,7 @@ msgstr "准备安装"
|
||||
#: pyanaconda/ui/gui/hubs/progress.glade:146
|
||||
msgctxt "GUI|Progress"
|
||||
msgid "_Finish configuration"
|
||||
-msgstr "完成配置(_F)"
|
||||
+msgstr "结束配置(_F)"
|
||||
|
||||
#: pyanaconda/ui/gui/hubs/progress.glade:200
|
||||
msgctxt "GUI|Progress"
|
||||
diff --git a/pyanaconda/kickstart.py b/pyanaconda/kickstart.py
|
||||
index ac007f7..4229b2d 100644
|
||||
--- a/pyanaconda/kickstart.py
|
||||
+++ b/pyanaconda/kickstart.py
|
||||
@@ -2209,8 +2209,8 @@ class Timezone(RemovedCommand):
|
||||
if not timezone.is_valid_timezone(kickstart_timezone):
|
||||
# this should never happen, but for pity's sake
|
||||
timezone_log.warning("Timezone %s set in kickstart is not valid, falling "
|
||||
- "back to default (America/New_York).", kickstart_timezone)
|
||||
- timezone_proxy.SetTimezone("America/New_York")
|
||||
+ "back to default (Asia/Shanghai).", kickstart_timezone)
|
||||
+ timezone_proxy.SetTimezone("Asia/Shanghai")
|
||||
|
||||
timezone.write_timezone_config(timezone_proxy, util.getSysroot())
|
||||
|
||||
diff --git a/pyanaconda/modules/timezone/timezone.py b/pyanaconda/modules/timezone/timezone.py
|
||||
index aa65563..7137086 100644
|
||||
--- a/pyanaconda/modules/timezone/timezone.py
|
||||
+++ b/pyanaconda/modules/timezone/timezone.py
|
||||
@@ -34,7 +34,7 @@ class TimezoneModule(KickstartModule):
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.timezone_changed = Signal()
|
||||
- self._timezone = "America/New_York"
|
||||
+ self._timezone = "Asia/Shanghai"
|
||||
|
||||
self.is_utc_changed = Signal()
|
||||
self._is_utc = False
|
||||
diff --git a/pyanaconda/ui/gui/spokes/datetime_spoke.py b/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
index 93594e2..5636809 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
@@ -64,7 +64,7 @@ SERVER_POOL = 1
|
||||
SERVER_WORKING = 2
|
||||
SERVER_USE = 3
|
||||
|
||||
-DEFAULT_TZ = "America/New_York"
|
||||
+DEFAULT_TZ = "Asia/Shanghai"
|
||||
|
||||
SPLIT_NUMBER_SUFFIX_RE = re.compile(r'([^0-9]*)([-+])([0-9]+)')
|
||||
|
||||
diff --git a/tests/nosetests/pyanaconda_tests/module_timezone_test.py b/tests/nosetests/pyanaconda_tests/module_timezone_test.py
|
||||
index 71cf6f6..e1fd63b 100644
|
||||
--- a/tests/nosetests/pyanaconda_tests/module_timezone_test.py
|
||||
+++ b/tests/nosetests/pyanaconda_tests/module_timezone_test.py
|
||||
@@ -78,7 +78,7 @@ class TimezoneInterfaceTestCase(unittest.TestCase):
|
||||
ks_in = None
|
||||
ks_out = """
|
||||
# System timezone
|
||||
- timezone America/New_York
|
||||
+ timezone Asia/Shanghai
|
||||
"""
|
||||
self._test_kickstart(ks_in, ks_out)
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,27 +0,0 @@
|
||||
From 463d8440f5e0bdf626be5b652fbe8826924e759b Mon Sep 17 00:00:00 2001
|
||||
Date: Mon, 16 Dec 2019 16:20:27 +0800
|
||||
Subject: [PATCH] anaconda: modify interface is extended in Chinese mode
|
||||
|
||||
reason:modify interface is extended in Chinese mode
|
||||
|
||||
Change-Id: I037a91028fc14792909efcc8c2946b0cacc78125
|
||||
---
|
||||
anaconda-29.24.7/po/zh_CN.po | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index 9b1da8c..c492042 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -6062,7 +6062,7 @@ msgstr "搜索方式(_B):"
|
||||
|
||||
#: pyanaconda/ui/gui/spokes/advanced_storage.glade:153
|
||||
msgid "Port / Target / LUN #"
|
||||
-msgstr "端口 / 目标 / 逻辑单位数标示符 (LUN #) "
|
||||
+msgstr "端口/目标/LUN# "
|
||||
|
||||
#: pyanaconda/ui/gui/spokes/advanced_storage.glade:154
|
||||
msgid "Target WWID"
|
||||
--
|
||||
2.19.1
|
||||
|
||||
@ -1,20 +0,0 @@
|
||||
diff -uNrp a/pyanaconda/core/util.py b/pyanaconda/core/util.py
|
||||
--- a/pyanaconda/core/util.py 2018-10-09 03:00:59.000000000 +0800
|
||||
+++ b/pyanaconda/core/util.py 2019-09-26 11:09:49.580000000 +0800
|
||||
@@ -1354,7 +1354,6 @@ def collect(module_pattern, path, pred):
|
||||
module_path = None
|
||||
|
||||
try:
|
||||
- imp.acquire_lock()
|
||||
(fo, module_path, module_flags) = imp.find_module(mod_name, [path])
|
||||
module = sys.modules.get(module_pattern % mod_name)
|
||||
|
||||
@@ -1427,8 +1426,6 @@ def collect(module_pattern, path, pred):
|
||||
log.error("Failed to import module %s from path %s in collect: %s", mod_name, module_path, imperr)
|
||||
continue
|
||||
finally:
|
||||
- imp.release_lock()
|
||||
-
|
||||
if mod_info and mod_info[0]: # pylint: disable=unsubscriptable-object
|
||||
mod_info[0].close() # pylint: disable=unsubscriptable-object
|
||||
|
||||
@ -1,26 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/root_password.py anaconda-29.24.7/pyanaconda/ui/gui/spokes/root_password.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/root_password.py 2019-01-30 20:34:33.200096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/root_password.py 2019-01-31 01:49:17.967096820 -0500
|
||||
@@ -229,8 +229,7 @@
|
||||
self.show_warning_message(error_message)
|
||||
else:
|
||||
# add suffix for the click twice logic
|
||||
- self.show_warning_message("{} {}".format(error_message,
|
||||
- _(constants.PASSWORD_DONE_TWICE)))
|
||||
+ self.show_warning_message(error_message)
|
||||
|
||||
# check if the spoke can be exited after the latest round of checks
|
||||
self._check_spoke_exit_conditions(unwaivable_check_failed)
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/user.py anaconda-29.24.7/pyanaconda/ui/gui/spokes/user.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/user.py 2019-01-30 20:34:33.200096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/user.py 2019-01-31 01:48:23.643096820 -0500
|
||||
@@ -593,8 +593,7 @@
|
||||
self.show_warning_message(error_message)
|
||||
else:
|
||||
# add suffix for the click twice logic
|
||||
- self.show_warning_message("{} {}".format(error_message,
|
||||
- _(constants.PASSWORD_DONE_TWICE)))
|
||||
+ self.show_warning_message(error_message)
|
||||
|
||||
# check if the spoke can be exited after the latest round of checks
|
||||
self._check_spoke_exit_conditions(unwaivable_check_failed)
|
||||
@ -1,41 +0,0 @@
|
||||
From b30a435ce81526e07af1bd83f4afe0e472c054bb Mon Sep 17 00:00:00 2001
|
||||
From: fanghuiyu <fanghuiyu@huawei.com>
|
||||
Date: Mon, 30 Sep 2019 16:46:54 +0800
|
||||
Subject: [PATCH] anaconda: skip checks if no username is set
|
||||
|
||||
reason: skip checks if no username is set
|
||||
|
||||
Change-Id: Ia18055e17b4014be05eef3b3f9175b5df635a1a5
|
||||
Signed-off-by: fanghuiyu <fanghuiyu@huawei.com>
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/user.py | 7 +++++--
|
||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/user.py b/pyanaconda/ui/gui/spokes/user.py
|
||||
index f2fd63a..54525e2 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/user.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/user.py
|
||||
@@ -312,6 +312,9 @@ class UserSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler):
|
||||
self._validity_check.result.status_text_changed.connect(self.set_password_status)
|
||||
# check if the password contains non-ascii characters
|
||||
self._ascii_check = input_checking.PasswordASCIICheck()
|
||||
+ # Skip the empty and validity password checks if no username is set
|
||||
+ self._empty_check.skip = True
|
||||
+ self._validity_check.skip = True
|
||||
|
||||
# register the individual checks with the checker in proper order
|
||||
# 0) is the username and fullname valid ?
|
||||
@@ -474,9 +477,9 @@ class UserSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler):
|
||||
self.password_confirmation_entry.set_sensitive(password_is_required)
|
||||
|
||||
# also disable/enable corresponding password checks
|
||||
- self._empty_check.skip = not password_is_required
|
||||
+ self._empty_check.skip = not password_is_required or not self.username
|
||||
self._confirm_check.skip = not password_is_required
|
||||
- self._validity_check.skip = not password_is_required
|
||||
+ self._validity_check.skip = not password_is_required or not self.username
|
||||
self._ascii_check.skip = not password_is_required
|
||||
|
||||
# and rerun the checks
|
||||
--
|
||||
2.19.1
|
||||
251
anaconda.spec
251
anaconda.spec
@ -1,76 +1,80 @@
|
||||
%define livearches %{ix86} x86_64
|
||||
%define _empty_manifest_terminate_build 0
|
||||
Name: anaconda
|
||||
Version: 33.19
|
||||
Release: 1
|
||||
Summary: Graphical system installer
|
||||
License: GPLv2+ and MIT
|
||||
URL: http://fedoraproject.org/wiki/Anaconda
|
||||
Source0: https://github.com/rhinstaller/anaconda/archive/%{name}-%{version}.tar.bz2
|
||||
Source1: openeuler.conf
|
||||
|
||||
Name: anaconda
|
||||
Version: 29.24.7
|
||||
Release: 32
|
||||
Summary: Graphical system installer
|
||||
License: GPLv2+ and MIT
|
||||
URL: https://fedoraproject.org/wiki/Anaconda
|
||||
Source0: %{name}-%{version}.tar.bz2
|
||||
Patch6000: Fix-hiding-of-network-device-activation-switch.patch
|
||||
|
||||
Patch6000: anaconda-change-log-localtime-to-gmtime.patch
|
||||
Patch6001: bugfix-Increase-network-timeout-constant.patch
|
||||
Patch6002: bugfix-Set-timeout-for-all-session.get-calls.patch
|
||||
Patch6003: anaconda-not-acquire-the-lock-of-imp.patch
|
||||
Patch6004: anaconda-Set-up-LD_PRELOAD-for-the-Payloads-module.patch
|
||||
Patch6005: anaconda-add-a-temporary-hack-to-fix-installations-on-ppc64le.patch
|
||||
Patch9000: add-passwd-policy.patch
|
||||
Patch9001: fix-hostname-info.patch
|
||||
patch9002: add-passwd-check-policy.patch
|
||||
Patch9003: bugfix-fix-data-encrypt-weak-passphrase-save.patch
|
||||
Patch9004: disable-set-passwd-without-confirmation.patch
|
||||
Patch9005: bugfix-logo-display-in-low-screen-resolution.patch
|
||||
Patch9006: make-name-not-force-to-uppercase.patch
|
||||
Patch9007: bugfix-GUI-nfs-unknown-error.patch
|
||||
Patch9008: hide-help-button.patch
|
||||
Patch9009: modify-interface-is-extended-in-Chinese-mode.patch
|
||||
Patch9010: remove-vender-issue-in-netdev.patch
|
||||
Patch9011: modify-arguments-parsing.patch
|
||||
Patch9012: add-boot-options-for-smmu-and-crashkernel.patch
|
||||
Patch9013: disable-product-name-in-welcome-is-uppercase.patch
|
||||
Patch9014: modify-default-timezone.patch
|
||||
Patch9015: modify-network-hostname-dot-illegal.patch
|
||||
Patch9016: disable-ssh-login-checkbox.patch
|
||||
Patch9017: bugfix-add-kdump-parameter-into-kernel-cmdline.patch
|
||||
|
||||
Patch9000: bugfix-update-network-and-hostname-translation.patch
|
||||
Patch9001: add-password-policy.patch
|
||||
Patch9002: bugfix-add-check-url-while-no-network.patch
|
||||
Patch9003: anaconda-fix-hostname-info.patch
|
||||
Patch9004: add-openEuler-password-policy.patch
|
||||
Patch9005: anaconda-prohibit-press-done-twice.patch
|
||||
Patch9006: change_passwd_min_length_to_8.patch
|
||||
Patch9007: bugfix-fix-data-encrypt-weak-passphrase-save.patch
|
||||
Patch9008: bugfix-disable-set-password-without-confirmation.patch
|
||||
Patch9009: bugfix-set-right-eula-location.patch
|
||||
Patch9010: bugfix-aarch64-anaconda-do-not-use-console.patch
|
||||
Patch9011: bugfix-x86-bootloader-install-fail.patch
|
||||
Patch9012: force-set-root-password.patch
|
||||
Patch9013: anaconda-fix-logo-display-in-low-screen-resolution.patch
|
||||
Patch9014: anaconda-fix-rnotes-display-in-low-screen-resolution.patch
|
||||
Patch9015: anaconda-make-name-not-force-to-uppercase.patch
|
||||
Patch9016: anaconda-add-moreos-install-class.patch
|
||||
Patch9017: anaconda-fix-password-expired.patch
|
||||
Patch9018: anaconda-fix-GUI-nfs-unknown-error.patch
|
||||
Patch9019: anaconda-change-topbar-background-size.patch
|
||||
Patch9020: anaconda-hide-help-button.patch
|
||||
Patch9021: anaconda-add-quiet-cmdline-args-for-x86.patch
|
||||
Patch9022: anaconda-modify-interface-is-extended-in-Chinese-mod.patch
|
||||
Patch9023: bugfix-fix-vender-issue.patch
|
||||
Patch9024: bugfix-disable-adding-virtual-device-in-network-spokes.patch
|
||||
Patch9025: bugfix-for-encrypting-partion.patch
|
||||
Patch9026: bugfix-modify-arguments-parsing.patch
|
||||
Patch9027: anaconda-add-boot-options-for-raid-3408.patch
|
||||
Patch9028: anaconda-add-kdump-parameter-into-kernel-cmdline.patch
|
||||
Patch9029: anaconda-skip-checks-if-no-username-is-set.patch
|
||||
Patch9030: anaconda-modify-openeuler-in-welcome-to-lowercase.patch
|
||||
Patch9031: bugfix-setup-fail-in-decode.patch
|
||||
Patch9032: anaconda-modify-default-timezone-and-zh_CN_po.patch
|
||||
Patch9033: bugfix-modify-network-hostname-dot-illegal.patch
|
||||
Patch9034: backport-Remove-initThreading-method-from-pyanaconda-threading.patch
|
||||
Patch9035: huawei-add-boot-options-for-dummy.patch
|
||||
Patch6001: anaconda-Fix-stage2-as-default-sources.patch
|
||||
Patch6002: anaconda-Allow-to-detect-devices-with-the-iso9660-file-system.patch
|
||||
|
||||
BuildRequires: audit-libs-devel libtool gettext-devel >= 0.19.8 gtk3-devel >= 3.22.17
|
||||
BuildRequires: gtk-doc gtk3-devel-docs >= 3.22.17 glib2-doc gobject-introspection-devel
|
||||
BuildRequires: glade-devel libgnomekbd-devel libxklavier-devel >= 5.4 pango-devel
|
||||
BuildRequires: python3-kickstart >= 3.16-1 python3-devel python3-nose systemd
|
||||
BuildRequires: rpm-devel >= 4.10.0 libarchive-devel >= 3.0.4 gdk-pixbuf2-devel
|
||||
BuildRequires: libtimezonemap-devel >= 0.4.1-2 libxml2
|
||||
%define dbusver 1.2.3
|
||||
%define dnfver 3.6.0
|
||||
%define dracutver 034-7
|
||||
%define fcoeutilsver 1.0.12-3.20100323git
|
||||
%define gettextver 0.19.8
|
||||
%define gtk3ver 3.22.17
|
||||
%define helpver 22.1-1
|
||||
%define isomd5sum 1.0.10
|
||||
%define langtablever 0.0.49
|
||||
%define libarchivever 3.0.4
|
||||
%define libblockdevver 2.1
|
||||
%define libtimezonemapver 0.4.1-2
|
||||
%define libxklavierver 5.4
|
||||
%define mehver 0.23-1
|
||||
%define nmver 1.0
|
||||
%define pykickstartver 3.25-1
|
||||
%define pypartedver 2.5-2
|
||||
%define rpmver 4.10.0
|
||||
%define simplelinever 1.1-1
|
||||
%define utillinuxver 2.15.1
|
||||
%define dasbusver 0.4
|
||||
BuildRequires: python3-pygments
|
||||
|
||||
Requires: anaconda-core = %{version}-%{release}
|
||||
Requires: anaconda-tui = %{version}-%{release}
|
||||
Requires: libblockdev-plugins-all realmd isomd5sum kexec-tools
|
||||
Requires: createrepo_c tmux gdb rsync python3-meh-gui adwaita-icon-theme dracut-live
|
||||
Requires: tigervnc-server-minimal libxklavier libgnomekbd libtimezonemap xz
|
||||
Requires: nm-connection-editor keybinder3 anaconda-user-help yelp system-logos
|
||||
Requires: blivet-gui-runtime python3 dracut dracut-network python3-kickstart
|
||||
BuildRequires: audit-libs-devel libtool gettext-devel >= %{gettextver} gtk3-devel >= %{gtk3ver}
|
||||
BuildRequires: gtk-doc gtk3-devel-docs >= %{gtk3ver} glib2-doc gobject-introspection-devel
|
||||
BuildRequires: glade-devel libgnomekbd-devel libxklavier-devel >= %{libxklavierver} pango-devel
|
||||
BuildRequires: python3-kickstart >= %{pykickstartver} python3-devel python3-nose systemd
|
||||
BuildRequires: rpm-devel >= %{rpmver} libarchive-devel >= %{libarchivever} gdk-pixbuf2-devel
|
||||
BuildRequires: libtimezonemap-devel >= %{libtimezonemapver} libxml2
|
||||
BuildRequires: gsettings-desktop-schemas metacity
|
||||
|
||||
%ifarch %livearches
|
||||
BuildRequires: desktop-file-utils
|
||||
Requires: zenity fcoe-utils
|
||||
Requires: anaconda-core = %{version}-%{release}
|
||||
Requires: anaconda-tui = %{version}-%{release}
|
||||
Requires: libblockdev-plugins-all >= %{libblockdevver} realmd isomd5sum >= %{isomd5sum}
|
||||
Requires: kexec-tools createrepo_c tmux gdb rsync python3-meh-gui >= %{mehver}
|
||||
Requires: adwaita-icon-theme python3-kickstart
|
||||
Requires: tigervnc-server-minimal libxklavier >= %{libxklavierver} libgnomekbd
|
||||
Requires: libtimezonemap >= %{libtimezonemapver} xz
|
||||
Requires: nm-connection-editor keybinder3 anaconda-user-help >= %{helpver} yelp system-logos
|
||||
Requires: blivet-gui-runtime python3 dracut >= %{dracutver} dracut-network dracut-live
|
||||
%ifarch %{ix86} x86_64
|
||||
BuildRequires: desktop-file-utils
|
||||
Requires: zenity fcoe-utils >= %{fcoeutilsver}
|
||||
%endif
|
||||
|
||||
Provides: anaconda-gui = %{version}-%{release}
|
||||
@ -86,63 +90,65 @@ Provides: anaconda-install-env-deps = %{version}-%{release}
|
||||
Obsoletes: anaconda-install-env-deps < %{version}-%{release}
|
||||
|
||||
%description
|
||||
The 'anaconda' dracut module handles installer-specific boot tasks and
|
||||
options. This includes driver disks, kickstarts, and finding the anaconda
|
||||
runtime on NFS/HTTP/FTP servers or local disks.
|
||||
The anaconda package is a metapackage for the Anaconda installer.
|
||||
|
||||
%package core
|
||||
Summary: Core of the Anaconda installer
|
||||
Requires: python3-libs python3-dnf >= 3.6.0 python3-blivet >= 1:3.1.0-1
|
||||
Requires: python3-blockdev >= 2.1 rpm-python3 >= 4.10.0 python3-productmd
|
||||
Requires: libreport-anaconda >= 2.0.21-1 libselinux-python3 python3-meh >= 0.23-1
|
||||
Requires: python3-pyparted >= 2.5-2 python3-requests python3-requests-file
|
||||
Requires: python3-requests-ftp python3-kickstart langtable-data >= 0.0.34
|
||||
Requires: langtable-python3 >= 0.0.34 util-linux >= 2.15.1 python3-gobject-base
|
||||
Requires: python3-dbus python3-pwquality python3-systemd python3-pydbus
|
||||
Requires: cracklib-dicts python3-pytz teamd NetworkManager NetworkManager-libnm
|
||||
Requires: dhclient kbd chrony python3-ntplib systemd python3-pid
|
||||
Requires: python3-ordered-set >= 2.0.0 python3-coverage glibc-langpack-en
|
||||
Requires: anaconda-tui = %{version}-%{release}
|
||||
%package core
|
||||
Summary: Core of the Anaconda installer
|
||||
Requires: python3-libs python3-dnf >= %{dnfver} python3-blivet >= 1:3.2.2-1
|
||||
Requires: python3-blockdev >= %{libblockdevver} rpm-python3 >= %{rpmver} python3-productmd
|
||||
Requires: libreport-anaconda >= 2.0.21-1 libselinux-python3 python3-meh >= %{mehver}
|
||||
Requires: python3-pyparted >= %{pypartedver} python3-requests python3-requests-file
|
||||
Requires: python3-requests-ftp python3-kickstart >= %{pykickstartver}
|
||||
Requires: python3-langtable >= %{langtablever} util-linux >= %{utillinuxver} python3-gobject-base
|
||||
Requires: python3-dbus python3-pwquality python3-systemd python3-dasbus >= %{dasbusver}
|
||||
Requires: cracklib-dicts python3-pytz teamd NetworkManager >= %{nmver} NetworkManager-libnm >= %{nmver}
|
||||
Requires: NetworkManager-team dhclient kbd chrony python3-ntplib systemd python3-pid
|
||||
Requires: python3-ordered-set >= 2.0.0 glibc-langpack-en dbus-daemon
|
||||
Requires: flatpak-libs
|
||||
# required because of the rescue mode and VNC question
|
||||
Requires: anaconda-tui = %{version}-%{release}
|
||||
Provides: anaconda-images = %{version}-%{release}
|
||||
Obsoletes: anaconda-images <= 10
|
||||
Provides: anaconda-runtime = %{version}-%{release}
|
||||
Obsoletes: anaconda-runtime < %{version}-%{release}
|
||||
Obsoletes: booty <= 0.107-1
|
||||
|
||||
Provides: anaconda-images = %{version}-%{release}
|
||||
Obsoletes: anaconda-images < %{version}-%{release}
|
||||
# Ensure it's not possible for a version of grubby to be installed
|
||||
# that doesn't work with btrfs subvolumes correctly...
|
||||
Conflicts: grubby < 8.40-10
|
||||
|
||||
Provides: anaconda-runtime = %{version}-%{release}
|
||||
Obsoletes: anaconda-runtime < %{version}-%{release}
|
||||
Obsoletes: booty <= 0.107-1
|
||||
|
||||
%ifarch %livearches
|
||||
Requires: usermode
|
||||
%ifarch %{ix86} x86_64
|
||||
Requires: usermode
|
||||
%endif
|
||||
|
||||
%description core
|
||||
%description core
|
||||
The anaconda-core package contains the program which was used to install your
|
||||
system.
|
||||
|
||||
%package tui
|
||||
Summary: Textual user interface for the Anaconda installer
|
||||
Requires: anaconda-core = %{version}-%{release} python3-simpleline
|
||||
%package tui
|
||||
Summary: Textual user interface for the Anaconda installer
|
||||
Requires: anaconda-core = %{version}-%{release} python3-simpleline >= %{simplelinever}
|
||||
|
||||
%description tui
|
||||
%description tui
|
||||
This package contains textual user interface for the Anaconda installer.
|
||||
|
||||
%package devel
|
||||
Summary: Header files for anaconda
|
||||
Requires: glade %{name} = %{version}-%{release}
|
||||
Provides: anaconda-widgets-devel = %{version}-%{release}
|
||||
Obsoletes: anaconda-widgets-devel < %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
Header files for anaconda
|
||||
%package devel
|
||||
Summary: Development files for anaconda-widgets
|
||||
Requires: glade
|
||||
Requires: %{name}-widgets = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package contains libraries and header files needed for writing the anaconda
|
||||
installer. It also contains Python and Glade support files, as well as
|
||||
documentation for working with this library.
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version} -p1
|
||||
|
||||
cd pyanaconda/installclasses
|
||||
sed -i "s/more_os_name/%{efi_vendor}/g" more_os_name.py
|
||||
mv more_os_name.py %{efi_vendor}.py
|
||||
|
||||
%build
|
||||
# use actual build-time release number, not tarball creation time release number
|
||||
%configure ANACONDA_RELEASE=%{release}
|
||||
%make_build
|
||||
|
||||
@ -150,15 +156,22 @@ mv more_os_name.py %{efi_vendor}.py
|
||||
%make_install
|
||||
%delete_la
|
||||
|
||||
# install openEuler conf for anaconda
|
||||
install -m 0755 %{SOURCE1} %{buildroot}/%{_sysconfdir}/%{name}/product.d/
|
||||
|
||||
# Create an empty directory for addons
|
||||
install -d -m 0755 %{buildroot}%{_datadir}/anaconda/addons
|
||||
|
||||
%ifarch %livearches
|
||||
%ifarch %{ix86} x86_64
|
||||
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{buildroot}%{_datadir}/applications/liveinst.desktop
|
||||
%endif
|
||||
|
||||
# If no langs found, keep going
|
||||
%find_lang %{name} || :
|
||||
|
||||
%ldconfig_scriptlets
|
||||
|
||||
%ifarch %livearches
|
||||
%ifarch %{ix86} x86_64
|
||||
%post
|
||||
update-desktop-database &> /dev/null || :
|
||||
|
||||
@ -168,7 +181,6 @@ update-desktop-database &> /dev/null || :
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc README
|
||||
%license COPYING
|
||||
%{_libdir}/libAnacondaWidgets.so.*
|
||||
%{_libdir}/girepository*/AnacondaWidgets*typelib
|
||||
@ -177,9 +189,8 @@ update-desktop-database &> /dev/null || :
|
||||
%{_prefix}/libexec/anaconda/dd_*
|
||||
%{_prefix}/lib/dracut/modules.d/80%{name}/*
|
||||
|
||||
%files core
|
||||
%files core
|
||||
%defattr(-,root,root)
|
||||
%doc README
|
||||
%license COPYING
|
||||
%{_sbindir}/anaconda
|
||||
%{_sbindir}/handle-sshpw
|
||||
@ -202,7 +213,14 @@ update-desktop-database &> /dev/null || :
|
||||
%exclude %{python3_sitearch}/pyanaconda/__pycache__/rescue.*
|
||||
%exclude %{python3_sitearch}/pyanaconda/ui/gui/*
|
||||
%exclude %{python3_sitearch}/pyanaconda/ui/tui/*
|
||||
%ifarch %livearches
|
||||
%{_bindir}/analog
|
||||
%{_bindir}/anaconda-cleanup
|
||||
%dir %{_sysconfdir}/%{name}
|
||||
%config %{_sysconfdir}/%{name}/*
|
||||
%dir %{_sysconfdir}/%{name}/conf.d
|
||||
%config %{_sysconfdir}/%{name}/conf.d/*
|
||||
%dir %{_sysconfdir}/%{name}/product.d
|
||||
%config %{_sysconfdir}/%{name}/product.d/*
|
||||
%{_sbindir}/liveinst
|
||||
%{_bindir}/liveinst
|
||||
%{_libexecdir}/liveinst-setup.sh
|
||||
@ -210,20 +228,23 @@ update-desktop-database &> /dev/null || :
|
||||
%{_sysconfdir}/xdg/autostart/*.desktop
|
||||
%config(noreplace) %{_sysconfdir}/pam.d/*
|
||||
%config(noreplace) %{_sysconfdir}/security/console.apps/*
|
||||
%endif
|
||||
|
||||
%files tui
|
||||
%files tui
|
||||
%{python3_sitearch}/pyanaconda/rescue.py
|
||||
%{python3_sitearch}/pyanaconda/__pycache__/rescue.*
|
||||
%{python3_sitearch}/pyanaconda/ui/tui/*
|
||||
|
||||
%files devel
|
||||
%files devel
|
||||
%{_libdir}/libAnacondaWidgets.so
|
||||
%{_libdir}/glade/modules/libAnacondaWidgets.so
|
||||
%{_includedir}/*
|
||||
%{_datadir}/glade/catalogs/AnacondaWidgets.xml
|
||||
%{_datadir}/gtk-doc
|
||||
|
||||
%changelog
|
||||
* Thu Aug 27 2020 hanzhijun <hanzhijun1@huawei.com> - 33.19-1
|
||||
- update version to 33.19
|
||||
|
||||
* Mon Aug 24 2020 yanan <yanan@huawei.com> - 29.24.7-32
|
||||
- Type:bugfix
|
||||
- Id:NA
|
||||
|
||||
@ -1,69 +0,0 @@
|
||||
From 05bda4c50c9df594a6b266ac74b60478da4c532c Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Wed, 12 Feb 2020 15:52:08 +0800
|
||||
Subject: [PATCH] Remove initThreading method from pyanaconda threading
|
||||
|
||||
---
|
||||
anaconda.py | 5 +----
|
||||
pyanaconda/threading.py | 17 +----------------
|
||||
2 files changed, 2 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/anaconda.py b/anaconda.py
|
||||
index 14048e7..52c8826 100755
|
||||
--- a/anaconda.py
|
||||
+++ b/anaconda.py
|
||||
@@ -274,10 +274,7 @@ if __name__ == "__main__":
|
||||
setup_python_path()
|
||||
|
||||
# init threading before Gtk can do anything and before we start using threads
|
||||
- # initThreading initializes the threadMgr instance, import it afterwards
|
||||
- from pyanaconda.threading import initThreading, AnacondaThread, threadMgr
|
||||
- initThreading()
|
||||
-
|
||||
+ from pyanaconda.threading import AnacondaThread, threadMgr
|
||||
from pyanaconda.core.i18n import _
|
||||
|
||||
from pyanaconda.addons import collect_addon_paths
|
||||
diff --git a/pyanaconda/threading.py b/pyanaconda/threading.py
|
||||
index a86003d..e0ab802 100644
|
||||
--- a/pyanaconda/threading.py
|
||||
+++ b/pyanaconda/threading.py
|
||||
@@ -44,10 +44,6 @@ class ThreadManager(object):
|
||||
self._objs_lock = threading.RLock()
|
||||
self._errors = {}
|
||||
self._errors_lock = threading.RLock()
|
||||
- self._main_thread = threading.main_thread()
|
||||
-
|
||||
- def set_current_thread_as_main(self):
|
||||
- self._main_thread = threading.current_thread()
|
||||
|
||||
def __call__(self):
|
||||
return self
|
||||
@@ -176,9 +172,7 @@ class ThreadManager(object):
|
||||
|
||||
def in_main_thread(self):
|
||||
"""Return True if it is run in the main thread."""
|
||||
-
|
||||
- cur_thread = threading.current_thread()
|
||||
- return cur_thread is self._main_thread
|
||||
+ return threading.current_thread() is threading.main_thread()
|
||||
|
||||
@property
|
||||
def running(self):
|
||||
@@ -293,13 +287,4 @@ class AnacondaThread(threading.Thread):
|
||||
self._target_stopped()
|
||||
|
||||
|
||||
-def initThreading():
|
||||
- """Set up threading for anaconda's use. This method must be called before
|
||||
- any GTK or threading code is called, or else threads will only run when
|
||||
- an event is triggered in the GTK main loop. And IT HAS TO BE CALLED IN
|
||||
- THE MAIN THREAD.
|
||||
- """
|
||||
- threadMgr.set_current_thread_as_main()
|
||||
-
|
||||
-
|
||||
threadMgr = ThreadManager()
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
26
bugfix-GUI-nfs-unknown-error.patch
Normal file
26
bugfix-GUI-nfs-unknown-error.patch
Normal file
@ -0,0 +1,26 @@
|
||||
From 7af95c3ee0fe3f0c2a5ec6fb05673f10c19441f9 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 22:48:03 +0800
|
||||
Subject: [PATCH] bugfix GUI nfs unknown error
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/installation_source.py | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/installation_source.py b/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
index 396cad6..16e81b4 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
@@ -1141,6 +1141,9 @@ class SourceSpoke(NormalSpoke, GUISpokeInputCheckHandler, SourceSwitchHandler):
|
||||
else:
|
||||
return _("Remote directory is required")
|
||||
|
||||
+ if ":" not in url_string or len(url_string.split(":")) != 2:
|
||||
+ return _("Server must be specified as SERVER:/PATH")
|
||||
+
|
||||
return InputCheck.CHECK_OK
|
||||
|
||||
def _check_url_entry(self, inputcheck):
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,39 +0,0 @@
|
||||
From 141c186c027a3a7b21321901bba024cd3a3dc3b7 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Konecny <jkonecny@redhat.com>
|
||||
Date: Mon, 12 Aug 2019 10:31:31 +0200
|
||||
Subject: [PATCH] Increase network timeout constant
|
||||
|
||||
The original value (45) is not recommended for the use in as timeout for
|
||||
the requests connection because it's multiple of 3.
|
||||
|
||||
See requests documentation:
|
||||
|
||||
https://3.python-requests.org/user/advanced/#timeouts
|
||||
|
||||
Increase to 46 to make the situation better.
|
||||
|
||||
This unfortunately change also three timeouts in the network.py which
|
||||
is a side effect but I'm not convinced we want to create a new constant
|
||||
for just 1 second difference.
|
||||
---
|
||||
pyanaconda/core/constants.py | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/core/constants.py b/pyanaconda/core/constants.py
|
||||
index ebc803e6cb..68f7fcb1c0 100644
|
||||
--- a/pyanaconda/core/constants.py
|
||||
+++ b/pyanaconda/core/constants.py
|
||||
@@ -103,7 +103,11 @@
|
||||
GRAPHICAL_TARGET = 'graphical.target'
|
||||
|
||||
# Network
|
||||
-NETWORK_CONNECTION_TIMEOUT = 45 # in seconds
|
||||
+
|
||||
+# Requests package (where this constant is used) recommends to have timeout slightly
|
||||
+# above multiple of 3 because of it is default packet re-transmission window.
|
||||
+# See: https://3.python-requests.org/user/advanced/#timeouts
|
||||
+NETWORK_CONNECTION_TIMEOUT = 46 # in seconds
|
||||
NETWORK_CONNECTED_CHECK_INTERVAL = 0.1 # in seconds
|
||||
|
||||
# DBus
|
||||
|
||||
@ -1,90 +0,0 @@
|
||||
From 5ba4ed1d0fb6c8d5109cf2fcc44841ddd485a979 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Konecny <jkonecny@redhat.com>
|
||||
Date: Mon, 12 Aug 2019 10:28:37 +0200
|
||||
Subject: [PATCH] Set timeout for all session.get calls
|
||||
|
||||
Based on the documentation for python requests library we should always
|
||||
specify the timeout command to avoid long timeouts.
|
||||
|
||||
See:
|
||||
https://3.python-requests.org/user/advanced/#timeouts
|
||||
|
||||
Set the timeout parameter to all the calls.
|
||||
|
||||
Reported-by: HangyuTian (github)
|
||||
---
|
||||
pyanaconda/payload/dnfpayload.py | 3 ++-
|
||||
pyanaconda/payload/__init__.py | 3 ++-
|
||||
pyanaconda/payload/livepayload.py | 8 +++++---
|
||||
3 files changed, 10 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/payload/dnfpayload.py b/pyanaconda/payload/dnfpayload.py
|
||||
index 477538e6c6..663387b4e1 100644
|
||||
--- a/pyanaconda/payload/dnfpayload.py
|
||||
+++ b/pyanaconda/payload/dnfpayload.py
|
||||
@@ -1450,7 +1450,8 @@ def _download_repoMD(self, method):
|
||||
for url in self._urls:
|
||||
try:
|
||||
result = session.get("%s/repodata/repomd.xml" % url, headers=headers,
|
||||
- proxies=proxies, verify=sslverify)
|
||||
+ proxies=proxies, verify=sslverify,
|
||||
+ timeout=constants.NETWORK_CONNECTION_TIMEOUT)
|
||||
if result.ok:
|
||||
repomd = result.text
|
||||
break
|
||||
--- a/pyanaconda/payload/__init__.py 2018-09-13 23:26:54.000000000 +0800
|
||||
+++ b/pyanaconda/payload/__init__.py 2019-08-14 16:41:01.134000000 +0800
|
||||
@@ -45,7 +45,7 @@
|
||||
|
||||
from pyanaconda.core.constants import DRACUT_ISODIR, DRACUT_REPODIR, DD_ALL, DD_FIRMWARE, \
|
||||
DD_RPMS, INSTALL_TREE, ISO_DIR, THREAD_STORAGE, THREAD_PAYLOAD, THREAD_PAYLOAD_RESTART, \
|
||||
- THREAD_WAIT_FOR_CONNECTING_NM, PayloadRequirementType, GRAPHICAL_TARGET, TEXT_ONLY_TARGET
|
||||
+ THREAD_WAIT_FOR_CONNECTING_NM, PayloadRequirementType, GRAPHICAL_TARGET, TEXT_ONLY_TARGET, NETWORK_CONNECTION_TIMEOUT
|
||||
from pyanaconda.modules.common.constants.services import SERVICES
|
||||
from pykickstart.constants import GROUP_ALL, GROUP_DEFAULT, GROUP_REQUIRED
|
||||
from pyanaconda.flags import flags
|
||||
@@ -734,7 +734,8 @@
|
||||
def _download_treeinfo_file(self, url, file_name, headers, proxies, verify):
|
||||
try:
|
||||
result = self._session.get("%s/%s" % (url, file_name), headers=headers,
|
||||
- proxies=proxies, verify=verify)
|
||||
+ proxies=proxies, verify=verify,
|
||||
+ timeout=NETWORK_CONNECTION_TIMEOUT)
|
||||
# Server returned HTTP 4XX or 5XX codes
|
||||
if result.status_code >= 400 and result.status_code < 600:
|
||||
log.info("Server returned %i code", result.status_code)
|
||||
diff --git a/pyanaconda/payload/livepayload.py b/pyanaconda/payload/livepayload.py
|
||||
index 79ad6b4d69..a96e8e7948 100644
|
||||
--- a/pyanaconda/payload/livepayload.py
|
||||
+++ b/pyanaconda/payload/livepayload.py
|
||||
@@ -47,7 +47,7 @@
|
||||
from pyanaconda.payload import ImagePayload, PayloadSetupError, PayloadInstallError
|
||||
|
||||
from pyanaconda.core.constants import INSTALL_TREE, THREAD_LIVE_PROGRESS
|
||||
-from pyanaconda.core.constants import IMAGE_DIR, TAR_SUFFIX
|
||||
+from pyanaconda.core.constants import IMAGE_DIR, TAR_SUFFIX, NETWORK_CONNECTION_TIMEOUT
|
||||
|
||||
from pyanaconda.core import util
|
||||
|
||||
@@ -309,7 +309,8 @@ def _setup_url_image(self):
|
||||
|
||||
error = None
|
||||
try:
|
||||
- response = self._session.get(self.data.method.url, proxies=self._proxies, verify=True)
|
||||
+ response = self._session.get(self.data.method.url, proxies=self._proxies, verify=True,
|
||||
+ timeout=NETWORK_CONNECTION_TIMEOUT)
|
||||
|
||||
# At this point we know we can get the image and what its size is
|
||||
# Make a guess as to minimum size needed:
|
||||
@@ -328,7 +328,9 @@
|
||||
log.info("Starting image download")
|
||||
with open(self.image_path, "wb") as f:
|
||||
ssl_verify = not self.data.method.noverifyssl
|
||||
- response = self._session.get(self.data.method.url, proxies=self._proxies, verify=ssl_verify, stream=True)
|
||||
+ response = self._session.get(self.data.method.url, proxies=self._proxies,
|
||||
+ verify=ssl_verify, stream=True,
|
||||
+ timeout=NETWORK_CONNECTION_TIMEOUT)
|
||||
total_length = response.headers.get('content-length')
|
||||
if total_length is None: # no content length header
|
||||
# just download the file in one go and fake the progress reporting once done
|
||||
|
||||
@ -1,20 +0,0 @@
|
||||
--- a/pyanaconda/bootloader.py 2019-05-23 19:35:56.260000000 +0800
|
||||
+++ b/pyanaconda/bootloader.py 2019-05-23 21:37:08.028000000 +0800
|
||||
@@ -1531,8 +1531,15 @@
|
||||
# this is going to cause problems for systems containing multiple
|
||||
# linux installations or even multiple boot entries with different
|
||||
# boot arguments
|
||||
- log.info("bootloader.py: used boot args: %s ", self.boot_args)
|
||||
- defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % self.boot_args)
|
||||
+
|
||||
+ #on aarch64 do not set console=xxx
|
||||
+ if blivet.arch.is_aarch64():
|
||||
+ arg_str = "%s" % self.boot_args
|
||||
+ log.info("check boot args:%s",arg_str)
|
||||
+ arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
+
|
||||
+ log.info("bootloader.py: used boot args: %s ", arg_str)
|
||||
+ defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % arg_str)
|
||||
defaults.write("GRUB_DISABLE_RECOVERY=\"true\"\n")
|
||||
#defaults.write("GRUB_THEME=\"/boot/grub2/themes/system/theme.txt\"\n")
|
||||
defaults.close()
|
||||
@ -1,13 +0,0 @@
|
||||
diff -Nur anaconda-21.48.22.134.old/pyanaconda/ui/gui/spokes/installation_source.py anaconda-21.48.22.134/pyanaconda/ui/gui/spokes/installation_source.py
|
||||
--- anaconda-21.48.22.134.old/pyanaconda/ui/gui/spokes/installation_source.py 2018-12-10 08:21:57.762000000 -0500
|
||||
+++ anaconda-21.48.22.134/pyanaconda/ui/gui/spokes/installation_source.py 2018-12-10 08:22:51.126000000 -0500
|
||||
@@ -1069,9 +1069,6 @@
|
||||
|
||||
# This method is shared by the checks on urlEntry and repoUrlEntry
|
||||
def _checkURL(self, inputcheck, combo):
|
||||
- # Network is not up, don't check urls.
|
||||
- if not self._network_module.proxy.Connected:
|
||||
- return InputCheck.CHECK_OK
|
||||
|
||||
# If combo is not set inputcheck holds repo
|
||||
is_additional_repo = combo is None
|
||||
42
bugfix-add-kdump-parameter-into-kernel-cmdline.patch
Normal file
42
bugfix-add-kdump-parameter-into-kernel-cmdline.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From e8e0d299420138e95dae58fcd4b5669e72217947 Mon Sep 17 00:00:00 2001
|
||||
From: Jialong Chen <chenjialong@huawei.com>
|
||||
Date: Tue, 14 Jul 2020 21:45:01 +0800
|
||||
Subject: [PATCH] add kdump parameter into kernel cmdline
|
||||
|
||||
---
|
||||
pyanaconda/modules/storage/bootloader/grub2.py | 12 ++++++++++--
|
||||
1 file changed, 10 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/modules/storage/bootloader/grub2.py b/pyanaconda/modules/storage/bootloader/grub2.py
|
||||
index c6b7db4..57fb2e5 100644
|
||||
--- a/pyanaconda/modules/storage/bootloader/grub2.py
|
||||
+++ b/pyanaconda/modules/storage/bootloader/grub2.py
|
||||
@@ -17,6 +17,7 @@
|
||||
#
|
||||
import os
|
||||
import re
|
||||
+import blivet
|
||||
from _ped import PARTITION_BIOS_GRUB
|
||||
|
||||
from blivet.devicelibs import raid
|
||||
@@ -266,8 +267,15 @@ class GRUB2(BootLoader):
|
||||
# this is going to cause problems for systems containing multiple
|
||||
# linux installations or even multiple boot entries with different
|
||||
# boot arguments
|
||||
- log.info("bootloader.py: used boot args: %s ", self.boot_args)
|
||||
- defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % self.boot_args)
|
||||
+ arg_str = "%s" % self.boot_args
|
||||
+ if blivet.arch.is_aarch64():
|
||||
+ log.info("check boot args:%s", arg_str)
|
||||
+ arg_str += " crashkernel=1024M,high"
|
||||
+ else:
|
||||
+ arg_str += " crashkernel=512M"
|
||||
+
|
||||
+ log.info("bootloader.py: used boot args: %s ", arg_str)
|
||||
+ defaults.write("GRUB_CMDLINE_LINUX=\"%s\"\n" % arg_str)
|
||||
defaults.write("GRUB_DISABLE_RECOVERY=\"true\"\n")
|
||||
#defaults.write("GRUB_THEME=\"/boot/grub2/themes/system/theme.txt\"\n")
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,119 +0,0 @@
|
||||
From 234cfa065b655448f94e63ab1e80e0cb8cf3e94e Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Mon, 30 Dec 2019 14:38:08 +0800
|
||||
Subject: [PATCH] disable adding virtual device in network spokes
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/network.glade | 45 ----------------------------------
|
||||
pyanaconda/ui/gui/spokes/network.py | 18 +++++++-------
|
||||
2 files changed, 9 insertions(+), 54 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/network.glade b/pyanaconda/ui/gui/spokes/network.glade
|
||||
index c5d20ce..6624234 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/network.glade
|
||||
+++ b/pyanaconda/ui/gui/spokes/network.glade
|
||||
@@ -258,51 +258,6 @@
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
- <child>
|
||||
- <object class="GtkToolbar" id="devices_toolbar">
|
||||
- <property name="visible">True</property>
|
||||
- <property name="can_focus">False</property>
|
||||
- <property name="toolbar_style">icons</property>
|
||||
- <property name="show_arrow">False</property>
|
||||
- <property name="icon_size">1</property>
|
||||
- <child>
|
||||
- <object class="GtkToolButton" id="add_toolbutton">
|
||||
- <property name="width_request">42</property>
|
||||
- <property name="height_request">36</property>
|
||||
- <property name="visible">True</property>
|
||||
- <property name="can_focus">False</property>
|
||||
- <property name="use_underline">True</property>
|
||||
- <property name="icon_name">list-add-symbolic</property>
|
||||
- </object>
|
||||
- <packing>
|
||||
- <property name="expand">False</property>
|
||||
- <property name="homogeneous">True</property>
|
||||
- </packing>
|
||||
- </child>
|
||||
- <child>
|
||||
- <object class="GtkToolButton" id="remove_toolbutton">
|
||||
- <property name="width_request">42</property>
|
||||
- <property name="height_request">36</property>
|
||||
- <property name="visible">True</property>
|
||||
- <property name="can_focus">False</property>
|
||||
- <property name="use_underline">True</property>
|
||||
- <property name="icon_name">list-remove-symbolic</property>
|
||||
- </object>
|
||||
- <packing>
|
||||
- <property name="expand">False</property>
|
||||
- <property name="homogeneous">True</property>
|
||||
- </packing>
|
||||
- </child>
|
||||
- <style>
|
||||
- <class name="inline-toolbar"/>
|
||||
- </style>
|
||||
- </object>
|
||||
- <packing>
|
||||
- <property name="expand">False</property>
|
||||
- <property name="fill">True</property>
|
||||
- <property name="position">1</property>
|
||||
- </packing>
|
||||
- </child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">True</property>
|
||||
diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
|
||||
index 436e814..e84ac67 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/network.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/network.py
|
||||
@@ -291,12 +291,12 @@ class NetworkControlBox(GObject.GObject):
|
||||
self.client = client
|
||||
|
||||
# button for creating of virtual bond and vlan devices
|
||||
- self.builder.get_object("add_toolbutton").set_sensitive(True)
|
||||
- self.builder.get_object("add_toolbutton").connect("clicked",
|
||||
- self.on_add_device_clicked)
|
||||
- self.builder.get_object("remove_toolbutton").set_sensitive(False)
|
||||
- self.builder.get_object("remove_toolbutton").connect("clicked",
|
||||
- self.on_remove_device_clicked)
|
||||
+ #self.builder.get_object("add_toolbutton").set_sensitive(True)
|
||||
+ #self.builder.get_object("add_toolbutton").connect("clicked",
|
||||
+ # self.on_add_device_clicked)
|
||||
+ #self.builder.get_object("remove_toolbutton").set_sensitive(False)
|
||||
+ #self.builder.get_object("remove_toolbutton").connect("clicked",
|
||||
+ # self.on_remove_device_clicked)
|
||||
|
||||
not_supported = ["start_hotspot_button",
|
||||
"stop_hotspot_button",
|
||||
@@ -1069,7 +1069,7 @@ class NetworkControlBox(GObject.GObject):
|
||||
self.builder.get_object("label_wired_vlanid").hide()
|
||||
self.builder.get_object("heading_wired_parent").hide()
|
||||
self.builder.get_object("label_wired_parent").hide()
|
||||
- self.builder.get_object("remove_toolbutton").set_sensitive(False)
|
||||
+ #self.builder.get_object("remove_toolbutton").set_sensitive(False)
|
||||
elif dev_type in [NM.DeviceType.BOND,
|
||||
NM.DeviceType.TEAM,
|
||||
NM.DeviceType.BRIDGE]:
|
||||
@@ -1080,7 +1080,7 @@ class NetworkControlBox(GObject.GObject):
|
||||
self.builder.get_object("label_wired_vlanid").hide()
|
||||
self.builder.get_object("heading_wired_parent").hide()
|
||||
self.builder.get_object("label_wired_parent").hide()
|
||||
- self.builder.get_object("remove_toolbutton").set_sensitive(True)
|
||||
+ #self.builder.get_object("remove_toolbutton").set_sensitive(True)
|
||||
elif dev_type == NM.DeviceType.VLAN:
|
||||
notebook.set_current_page(0)
|
||||
self.builder.get_object("heading_wired_slaves").hide()
|
||||
@@ -1089,7 +1089,7 @@ class NetworkControlBox(GObject.GObject):
|
||||
self.builder.get_object("label_wired_vlanid").show()
|
||||
self.builder.get_object("heading_wired_parent").show()
|
||||
self.builder.get_object("label_wired_parent").show()
|
||||
- self.builder.get_object("remove_toolbutton").set_sensitive(True)
|
||||
+ #self.builder.get_object("remove_toolbutton").set_sensitive(True)
|
||||
elif dev_type == NM.DeviceType.WIFI:
|
||||
notebook.set_current_page(1)
|
||||
self.builder.get_object("button_wireless_options").set_sensitive(self.selected_ap is not None)
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,14 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7-old/pyanaconda/input_checking.py anaconda-29.24.7/pyanaconda/input_checking.py
|
||||
--- anaconda-29.24.7-old/pyanaconda/input_checking.py 2018-06-07 17:31:59.000000000 -0400
|
||||
+++ anaconda-29.24.7/pyanaconda/input_checking.py 2019-02-25 07:31:26.287338526 -0500
|
||||
@@ -472,6 +472,10 @@
|
||||
else:
|
||||
pw_score = 4
|
||||
status_text = _(constants.SecretStatus.STRONG.value)
|
||||
+
|
||||
+ #disable set password without confirnation
|
||||
+ if not error_message and not check_request.password_confirmation:
|
||||
+ error_message = _(constants.SECRET_CONFIRM_ERROR_GUI[check_request.secret_type])
|
||||
|
||||
# the policy influences the overall success of the check
|
||||
# - score 0 & strict == True -> success = False
|
||||
@ -1,7 +1,17 @@
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/lib/passphrase.py anaconda-29.24.7/pyanaconda/ui/gui/spokes/lib/passphrase.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/lib/passphrase.py 2019-01-30 20:34:33.204096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/ui/gui/spokes/lib/passphrase.py 2019-01-30 21:12:10.449096820 -0500
|
||||
@@ -167,7 +167,7 @@
|
||||
From e74a97aaf7e3f0e8d9b1f961eb68712337924720 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 17:30:22 +0800
|
||||
Subject: [PATCH] bugfix fix data encrypt weak passphrase save
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/lib/passphrase.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/lib/passphrase.py b/pyanaconda/ui/gui/spokes/lib/passphrase.py
|
||||
index 99ca2d4..0314d6d 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/lib/passphrase.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/lib/passphrase.py
|
||||
@@ -158,7 +158,7 @@ class PassphraseDialog(GUIObject):
|
||||
self._passphrase_good_enough = True
|
||||
elif len(self._checker.failed_checks) == 1 and self._validity_check in self._checker._failed_checks:
|
||||
# only the password validity check failed
|
||||
@ -10,3 +20,6 @@ diff -Nur anaconda-29.24.7.old/pyanaconda/ui/gui/spokes/lib/passphrase.py anacon
|
||||
# this is not fine for the strict password policy
|
||||
self._passphrase_good_enough = False
|
||||
else:
|
||||
--
|
||||
2.23.0
|
||||
|
||||
|
||||
@ -1,15 +0,0 @@
|
||||
diff -urNp a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
|
||||
--- a/pyanaconda/ui/gui/spokes/network.py 2018-07-25 21:58:20.000000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/spokes/network.py 2019-12-30 16:58:36.337887175 +0800
|
||||
@@ -877,9 +877,8 @@ class NetworkControlBox(GObject.GObject)
|
||||
unplugged)
|
||||
|
||||
if dev_cfg.device:
|
||||
- title += '\n<span size="small">%s %s</span>' % \
|
||||
- (escape_markup(dev_cfg.device.get_vendor() or ""),
|
||||
- escape_markup(dev_cfg.device.get_product() or ""))
|
||||
+ title += '\n<span size="small">%s</span>' % \
|
||||
+ (escape_markup(dev_cfg.device.get_product() or ""))
|
||||
return title
|
||||
|
||||
def dev_cfg(self, uuid=None, device=None, iface=None):
|
||||
@ -1,47 +0,0 @@
|
||||
From 213e913ffd1fd9f7ba48315fcb6644b8486f65ba Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Wed, 1 Jan 2020 04:26:27 +0800
|
||||
Subject: [PATCH] bugfix for encrypting partion
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/custom_storage.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/storage.py | 3 ++-
|
||||
2 files changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/custom_storage.py b/pyanaconda/ui/gui/spokes/custom_storage.py
|
||||
index 2eb72e6..0e52d01 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/custom_storage.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/custom_storage.py
|
||||
@@ -1611,7 +1611,7 @@ class CustomPartitioningSpoke(NormalSpoke, StorageCheckHandler):
|
||||
use_dev.exists and not use_dev.format_immutable)
|
||||
|
||||
self._encryptCheckbox.set_active(isinstance(device, LUKSDevice))
|
||||
- fancy_set_sensitive(self._encryptCheckbox, self._reformatCheckbox.get_active())
|
||||
+ fancy_set_sensitive(self._encryptCheckbox, False)
|
||||
|
||||
ancestors = use_dev.ancestors
|
||||
ancestors.remove(use_dev)
|
||||
diff --git a/pyanaconda/ui/gui/spokes/storage.py b/pyanaconda/ui/gui/spokes/storage.py
|
||||
index b57c44d..b3b6fba 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/storage.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/storage.py
|
||||
@@ -311,6 +311,7 @@ class StorageSpoke(NormalSpoke, StorageCheckHandler):
|
||||
self._cur_clicked_overview = None
|
||||
|
||||
self._grabObjects()
|
||||
+ self._encryption_revealer.set_reveal_child(False)
|
||||
|
||||
self._autoPart.connect("toggled", self._method_radio_button_toggled)
|
||||
self._customPart.connect("toggled", self._method_radio_button_toggled)
|
||||
@@ -369,7 +370,7 @@ class StorageSpoke(NormalSpoke, StorageCheckHandler):
|
||||
self._encryption_revealer.set_reveal_child(False)
|
||||
self._encrypted.set_active(False)
|
||||
else:
|
||||
- self._encryption_revealer.set_reveal_child(True)
|
||||
+ self._encryption_revealer.set_reveal_child(False)
|
||||
|
||||
# Hide the reclaim space checkbox if automatic storage configuration is not used.
|
||||
if self._get_selected_partitioning_method() == PartitioningMethod.AUTO:
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
24
bugfix-logo-display-in-low-screen-resolution.patch
Normal file
24
bugfix-logo-display-in-low-screen-resolution.patch
Normal file
@ -0,0 +1,24 @@
|
||||
From 3e4a2bd7fd23c458a96b387c4df9f4abb984d59f Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 22:30:28 +0800
|
||||
Subject: [PATCH] bugfix logo display in low screen resolution
|
||||
|
||||
---
|
||||
data/anaconda-gtk.css | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/data/anaconda-gtk.css b/data/anaconda-gtk.css
|
||||
index c47bb87..7b7166b 100644
|
||||
--- a/data/anaconda-gtk.css
|
||||
+++ b/data/anaconda-gtk.css
|
||||
@@ -113,6 +113,7 @@ infobar.error {
|
||||
.logo {
|
||||
background-image: url('/usr/share/anaconda/pixmaps/sidebar-logo.png');
|
||||
background-position: 50% 20px;
|
||||
+ background-size: 90%;
|
||||
background-repeat: no-repeat;
|
||||
background-color: transparent;
|
||||
}
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,25 +0,0 @@
|
||||
From 22e65d85d4e49ba25cc8f65eb9f74c899ece47ff Mon Sep 17 00:00:00 2001
|
||||
From: luochunsheng <luochunsheng@huawei.com>
|
||||
Date: Tue, 9 Apr 2019 17:14:23 +0800
|
||||
Subject: [PATCH] Subject: [PATCH] set right eula location
|
||||
|
||||
---
|
||||
pyanaconda/installclasses/rhel.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/installclasses/rhel.py b/pyanaconda/installclasses/rhel.py
|
||||
index 40de99f..e31f909 100644
|
||||
--- a/pyanaconda/installclasses/rhel.py
|
||||
+++ b/pyanaconda/installclasses/rhel.py
|
||||
@@ -48,7 +48,7 @@ class RHELBaseInstallClass(BaseInstallClass):
|
||||
help_placeholder_with_links = "rhel_help_placeholder.xml"
|
||||
help_placeholder_plain_text = "rhel_help_placeholder.txt"
|
||||
|
||||
- eula_path="/usr/share/redhat-release/EULA"
|
||||
+ eula_path="/usr/share/openEuler-release/EULA"
|
||||
|
||||
mirrors_available = False
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,24 +0,0 @@
|
||||
diff -urNp a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
|
||||
--- a/pyanaconda/bootloader.py 2020-01-16 20:01:15.862288105 +0800
|
||||
+++ b/pyanaconda/bootloader.py 2020-01-16 20:03:58.044568791 +0800
|
||||
@@ -2491,7 +2491,7 @@ def writeSysconfigKernel(storage, versio
|
||||
log.error("failed to get package name for default kernel")
|
||||
return
|
||||
|
||||
- kernel = h.name.decode()
|
||||
+ kernel = h.name.encode().decode()
|
||||
|
||||
f = open(util.getSysroot() + "/etc/sysconfig/kernel", "w+")
|
||||
f.write("# UPDATEDEFAULT specifies if new-kernel-pkg should make\n"
|
||||
diff -urNp a/pyanaconda/payload/__init__.py b/pyanaconda/payload/__init__.py
|
||||
--- a/pyanaconda/payload/__init__.py 2020-01-16 20:01:15.822287542 +0800
|
||||
+++ b/pyanaconda/payload/__init__.py 2020-01-16 20:03:32.604211014 +0800
|
||||
@@ -1112,7 +1112,7 @@ class PackagePayload(Payload):
|
||||
ts = rpm.TransactionSet(util.getSysroot())
|
||||
mi = ts.dbMatch('providename', 'kernel')
|
||||
for hdr in mi:
|
||||
- unicode_fnames = (f.decode("utf-8") for f in hdr.filenames)
|
||||
+ unicode_fnames = (f.encode().decode("utf-8") for f in hdr.filenames)
|
||||
# Find all /boot/vmlinuz- files and strip off vmlinuz-
|
||||
files.extend((f.split("/")[-1][8:] for f in unicode_fnames
|
||||
if fnmatch(f, "/boot/vmlinuz-*") or
|
||||
@ -1,21 +0,0 @@
|
||||
diff -Nuar anaconda-21.48.22.134.bak/po/zh_CN.po anaconda-21.48.22.134/po/zh_CN.po
|
||||
--- anaconda-21.48.22.134.bak/po/zh_CN.po 2018-11-03 17:59:45.609576566 +0800
|
||||
+++ anaconda-21.48.22.134/po/zh_CN.po 2018-11-03 18:00:47.868576566 +0800
|
||||
#@@ -788,7 +788,7 @@
|
||||
# #: pyanaconda/ui/gui/spokes/network.py:1536
|
||||
# msgctxt "GUI|Spoke"
|
||||
# msgid "_Network & Host Name"
|
||||
#-msgstr "网络和主机名(_N)"
|
||||
#+msgstr "网络和主机名"
|
||||
#
|
||||
# #: pyanaconda/ui/gui/spokes/network.py:1640
|
||||
# #: pyanaconda/ui/gui/spokes/network.py:1658
|
||||
@@ -5585,7 +5585,7 @@
|
||||
#: pyanaconda/ui/gui/spokes/network.glade:165
|
||||
#: pyanaconda/ui/gui/spokes/network.glade:2277
|
||||
msgid "NETWORK & HOST NAME"
|
||||
-msgstr "网络和主机名(_N)"
|
||||
+msgstr "网络和主机名"
|
||||
|
||||
#: pyanaconda/ui/gui/spokes/network.glade:204
|
||||
msgid ""
|
||||
@ -1,13 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7-old/pyanaconda/bootloader.py anaconda-29.24.7/pyanaconda/bootloader.py
|
||||
--- anaconda-29.24.7-old/pyanaconda/bootloader.py 2019-07-09 22:14:24.800000000 -0400
|
||||
+++ anaconda-29.24.7/pyanaconda/bootloader.py 2019-07-09 22:15:17.936000000 -0400
|
||||
@@ -1533,8 +1533,8 @@
|
||||
# boot arguments
|
||||
|
||||
#on aarch64 do not set console=xxx
|
||||
+ arg_str = "%s" % self.boot_args
|
||||
if blivet.arch.is_aarch64():
|
||||
- arg_str = "%s" % self.boot_args
|
||||
log.info("check boot args:%s",arg_str)
|
||||
arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
|
||||
@ -1,12 +0,0 @@
|
||||
diff -Nur anaconda-29.24.7.old/pyanaconda/core/constants.py anaconda-29.24.7/pyanaconda/core/constants.py
|
||||
--- anaconda-29.24.7.old/pyanaconda/core/constants.py 2019-01-30 20:34:33.221096820 -0500
|
||||
+++ anaconda-29.24.7/pyanaconda/core/constants.py 2019-01-31 03:37:25.427096820 -0500
|
||||
@@ -156,7 +156,7 @@
|
||||
PASSPHRASE = "passphrase"
|
||||
|
||||
# Password validation
|
||||
-SECRET_MIN_LEN = 6
|
||||
+SECRET_MIN_LEN = 8
|
||||
SECRET_EMPTY_ERROR = {
|
||||
SecretType.PASSWORD : N_("The password is empty."),
|
||||
SecretType.PASSPHRASE : N_("The passphrase is empty.")
|
||||
@ -1,16 +1,17 @@
|
||||
From 2c35b2f3ff077a2a43c64e908e89b26dde852091 Mon Sep 17 00:00:00 2001
|
||||
Date: Thu, 16 Jan 2020 15:11:50 +0800
|
||||
Subject: [PATCH] modify openeuler in welcome to lowercase
|
||||
From e1d294331217ec7380f7f186d7a6837e72770432 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 11:42:23 +0800
|
||||
Subject: [PATCH] disable-product-name-in-welcome-is-uppercase
|
||||
|
||||
---
|
||||
anaconda-29.24.7/pyanaconda/ui/gui/spokes/welcome.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/welcome.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/welcome.py b/pyanaconda/ui/gui/spokes/welcome.py
|
||||
index 2c60a6a..70213ec 100644
|
||||
index 3373f1d..639fdcd 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/welcome.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/welcome.py
|
||||
@@ -248,7 +248,7 @@ class WelcomeLanguageSpoke(LangLocaleHandler, StandaloneSpoke):
|
||||
@@ -251,7 +251,7 @@ class WelcomeLanguageSpoke(StandaloneSpoke, LangLocaleHandler):
|
||||
languageEntry.set_placeholder_text(_(self._origStrings[languageEntry]))
|
||||
|
||||
# And of course, don't forget the underlying window.
|
||||
@ -20,5 +21,5 @@ index 2c60a6a..70213ec 100644
|
||||
|
||||
# Retranslate the window title text
|
||||
--
|
||||
1.8.3.1
|
||||
2.23.0
|
||||
|
||||
27
disable-set-passwd-without-confirmation.patch
Normal file
27
disable-set-passwd-without-confirmation.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From a51168ce9ab849f857efd96eae66cff5247a45a4 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 17:35:01 +0800
|
||||
Subject: [PATCH] disable set passwd without confirmation
|
||||
|
||||
---
|
||||
pyanaconda/input_checking.py | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/pyanaconda/input_checking.py b/pyanaconda/input_checking.py
|
||||
index 9efbd7b..b0fd605 100644
|
||||
--- a/pyanaconda/input_checking.py
|
||||
+++ b/pyanaconda/input_checking.py
|
||||
@@ -412,6 +412,10 @@ class PasswordValidityCheck(InputCheck):
|
||||
pw_score = 4
|
||||
status_text = _(constants.SecretStatus.STRONG.value)
|
||||
|
||||
+ #disable set password without confirnation
|
||||
+ if not error_message and not check_request.password_confirmation:
|
||||
+ error_message = _(constants.SECRET_CONFIRM_ERROR_GUI[check_request.secret_type])
|
||||
+
|
||||
# the policy influences the overall success of the check
|
||||
# - score 0 & strict == True -> success = False
|
||||
# - score 0 & strict == False -> success = True
|
||||
--
|
||||
2.23.0
|
||||
|
||||
38
disable-ssh-login-checkbox.patch
Normal file
38
disable-ssh-login-checkbox.patch
Normal file
@ -0,0 +1,38 @@
|
||||
From 6920ff7aa9c0215a032e00a5406b943737903c72 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Wed, 1 Jul 2020 18:08:35 +0800
|
||||
Subject: [PATCH] disable ssh login checkbox
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/root_password.py | 8 +++++---
|
||||
1 file changed, 5 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/root_password.py b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
index 313ba0f..2af9111 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/root_password.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
@@ -72,6 +72,8 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler)
|
||||
self._password_label = self.builder.get_object("password_label")
|
||||
self._lock = self.builder.get_object("lock")
|
||||
self._root_password_ssh_login_override = self.builder.get_object("root_password_ssh_login_override")
|
||||
+ self._root_password_ssh_login_override.set_visible(False)
|
||||
+ self._root_password_ssh_login_override.set_no_show_all(True)
|
||||
|
||||
# Install the password checks:
|
||||
# - Has a password been specified?
|
||||
@@ -147,9 +149,9 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler)
|
||||
# we use the _refresh_running atribute to differentiate
|
||||
# it from "real" clicks
|
||||
self._lock.set_active(self._users_module.IsRootAccountLocked)
|
||||
- self._root_password_ssh_login_override.set_active(
|
||||
- self._users_module.RootPasswordSSHLoginAllowed
|
||||
- )
|
||||
+ self._root_password_ssh_login_override.set_visible(False)
|
||||
+ self._root_password_ssh_login_override.set_no_show_all(True)
|
||||
+
|
||||
if not self._lock.get_active():
|
||||
# rerun checks so that we have a correct status message, if any
|
||||
self.checker.run_checks()
|
||||
--
|
||||
2.23.0
|
||||
|
||||
47
fix-hostname-info.patch
Normal file
47
fix-hostname-info.patch
Normal file
@ -0,0 +1,47 @@
|
||||
From 8ecae3e85d9eeedb131dbc026dcdf5bba95cdb15 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 17:13:47 +0800
|
||||
Subject: [PATCH] fix hostname info
|
||||
|
||||
---
|
||||
po/zh_CN.po | 6 +++---
|
||||
pyanaconda/network.py | 4 ++--
|
||||
2 files changed, 5 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index 0a4d1cd..be8cefe 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -2365,11 +2365,11 @@ msgstr "本地主机名绝不能以句号\".\"结尾。"
|
||||
#: pyanaconda/network.py:119
|
||||
msgid ""
|
||||
"Host names can only contain the characters 'a-z', 'A-Z', '0-9', '-', or '.', "
|
||||
-"parts between periods must contain something and cannot start or end with "
|
||||
-"'-'."
|
||||
+"parts between periods must contain something being 63 or fewer "
|
||||
+"characters and cannot start or end with '-'."
|
||||
msgstr ""
|
||||
"主机名只能包含 'a-z', 'A-Z', '0-9', '-'(英文减号), 或者 '.'(英文点号),其"
|
||||
-"中两个点号中不能为空且不能以'-'开头或结尾。"
|
||||
+"中两个点号中不能为空,必须少于64个字符且不能以'-'开头或结尾。"
|
||||
|
||||
#: pyanaconda/network.py:465
|
||||
msgid "Status not available"
|
||||
diff --git a/pyanaconda/network.py b/pyanaconda/network.py
|
||||
index f8e9b19..127a1bd 100644
|
||||
--- a/pyanaconda/network.py
|
||||
+++ b/pyanaconda/network.py
|
||||
@@ -118,8 +118,8 @@ def is_valid_hostname(hostname, local=False):
|
||||
if not re.match('^' + HOSTNAME_PATTERN_WITHOUT_ANCHORS + '$', hostname):
|
||||
return (False, _("Host names can only contain the characters 'a-z', "
|
||||
"'A-Z', '0-9', '-', or '.', parts between periods "
|
||||
- "must contain something and cannot start or end with "
|
||||
- "'-'."))
|
||||
+ "must contain something being 63 or fewer "
|
||||
+ "characters and cannot start or end with '-'."))
|
||||
|
||||
return (True, "")
|
||||
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,27 +0,0 @@
|
||||
diff --git a/pyanaconda/ui/gui/spokes/root_password.py b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
index c2a99fe..d61ae9b 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/root_password.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/root_password.py
|
||||
@@ -166,7 +166,7 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalSpoke, GUISpokeInputCheckHandler)
|
||||
|
||||
@property
|
||||
def mandatory(self):
|
||||
- return not any(user for user in self.data.user.userList if "wheel" in user.groups)
|
||||
+ return True
|
||||
|
||||
def apply(self):
|
||||
pw = self.password
|
||||
diff --git a/pyanaconda/ui/tui/spokes/root_password.py b/pyanaconda/ui/tui/spokes/root_password.py
|
||||
index 5f3e157..7a83c99 100644
|
||||
--- a/pyanaconda/ui/tui/spokes/root_password.py
|
||||
+++ b/pyanaconda/ui/tui/spokes/root_password.py
|
||||
@@ -64,8 +64,7 @@ class PasswordSpoke(FirstbootSpokeMixIn, NormalTUISpoke):
|
||||
|
||||
@property
|
||||
def mandatory(self):
|
||||
- return not any(user for user in self.data.user.userList
|
||||
- if "wheel" in user.groups)
|
||||
+ return True
|
||||
|
||||
@property
|
||||
def status(self):
|
||||
@ -1,6 +1,18 @@
|
||||
diff -uNrp a/data/tmux.conf b/data/tmux.conf
|
||||
--- a/data/tmux.conf 2018-06-08 05:31:59.000000000 +0800
|
||||
+++ b/data/tmux.conf 2019-09-17 15:05:42.068000000 +0800
|
||||
From cf192d77045b8aeb8cdcd55c98a93ad64fea3c3b Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 09:20:14 +0800
|
||||
Subject: [PATCH] hide help button
|
||||
|
||||
---
|
||||
data/tmux.conf | 3 +--
|
||||
pyanaconda/ui/gui/__init__.py | 27 ---------------------------
|
||||
widgets/src/BaseWindow.c | 21 ---------------------
|
||||
3 files changed, 1 insertion(+), 50 deletions(-)
|
||||
|
||||
diff --git a/data/tmux.conf b/data/tmux.conf
|
||||
index 87c9cb7..63240f7 100644
|
||||
--- a/data/tmux.conf
|
||||
+++ b/data/tmux.conf
|
||||
@@ -1,7 +1,6 @@
|
||||
# tmux.conf for the anaconda environment
|
||||
|
||||
@ -9,7 +21,7 @@ diff -uNrp a/data/tmux.conf b/data/tmux.conf
|
||||
|
||||
set-option -s exit-unattached off
|
||||
set-option -g base-index 1
|
||||
@@ -20,7 +19,7 @@ set-option -g history-limit 10000
|
||||
@@ -25,7 +24,7 @@ set-option -g history-limit 10000
|
||||
# rhbz#1722181
|
||||
new-session -d -s anaconda -n main "LD_PRELOAD=libgomp.so.1 anaconda"
|
||||
|
||||
@ -18,10 +30,11 @@ diff -uNrp a/data/tmux.conf b/data/tmux.conf
|
||||
|
||||
new-window -d -n shell "bash --login"
|
||||
new-window -d -n log "tail -F /tmp/anaconda.log"
|
||||
diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
--- a/pyanaconda/ui/gui/__init__.py 2019-09-17 14:58:04.272000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/__init__.py 2019-09-17 15:05:42.068000000 +0800
|
||||
@@ -438,20 +438,6 @@ class MainWindow(Gtk.Window):
|
||||
diff --git a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
index 06373d9..6a6e3b9 100644
|
||||
--- a/pyanaconda/ui/gui/__init__.py
|
||||
+++ b/pyanaconda/ui/gui/__init__.py
|
||||
@@ -443,20 +443,6 @@ class MainWindow(Gtk.Window):
|
||||
# Return False to indicate that the child allocation is not yet set
|
||||
return False
|
||||
|
||||
@ -42,7 +55,7 @@ diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
def _on_child_added(self, widget, user_data):
|
||||
# If this is GtkLabel, apply the language attribute
|
||||
if isinstance(widget, Gtk.Label):
|
||||
@@ -475,8 +461,6 @@ class MainWindow(Gtk.Window):
|
||||
@@ -480,8 +466,6 @@ class MainWindow(Gtk.Window):
|
||||
old_screen = self._stack.get_visible_child()
|
||||
if old_screen:
|
||||
old_screen.remove_accelerator(self._accel_group, Gdk.KEY_F12, 0)
|
||||
@ -51,7 +64,7 @@ diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
|
||||
# Check if the widget is already on the stack
|
||||
if child not in self._stack_contents:
|
||||
@@ -493,17 +477,6 @@ class MainWindow(Gtk.Window):
|
||||
@@ -498,17 +482,6 @@ class MainWindow(Gtk.Window):
|
||||
child.window.add_accelerator("button-clicked", self._accel_group,
|
||||
Gdk.KEY_F12, 0, 0)
|
||||
|
||||
@ -69,9 +82,10 @@ diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
self._stack.set_visible_child(child.window)
|
||||
|
||||
if child.focusWidgetName:
|
||||
diff -uNrp a/widgets/src/BaseWindow.c b/widgets/src/BaseWindow.c
|
||||
--- a/widgets/src/BaseWindow.c 2018-06-08 05:31:59.000000000 +0800
|
||||
+++ b/widgets/src/BaseWindow.c 2019-09-17 15:08:23.324000000 +0800
|
||||
diff --git a/widgets/src/BaseWindow.c b/widgets/src/BaseWindow.c
|
||||
index 6a1e372..203d4a7 100644
|
||||
--- a/widgets/src/BaseWindow.c
|
||||
+++ b/widgets/src/BaseWindow.c
|
||||
@@ -393,30 +393,11 @@ G_GNUC_END_IGNORE_DEPRECATIONS
|
||||
gtk_widget_set_margin_top(win->priv->layout_indicator, 6);
|
||||
gtk_widget_set_margin_bottom(win->priv->layout_indicator, 6);
|
||||
@ -103,7 +117,7 @@ diff -uNrp a/widgets/src/BaseWindow.c b/widgets/src/BaseWindow.c
|
||||
|
||||
/* Last thing for the main_box is a revealer for the info bar */
|
||||
win->priv->info_revealer = gtk_revealer_new();
|
||||
@@ -832,8 +813,6 @@ void anaconda_base_window_retranslate(An
|
||||
@@ -832,8 +813,6 @@ void anaconda_base_window_retranslate(AnacondaBaseWindow *win) {
|
||||
|
||||
gtk_label_set_text(GTK_LABEL(win->priv->beta_label), _(win->priv->orig_beta));
|
||||
|
||||
@ -112,3 +126,6 @@ diff -uNrp a/widgets/src/BaseWindow.c b/widgets/src/BaseWindow.c
|
||||
/* retranslate the layout indicator */
|
||||
anaconda_layout_indicator_retranslate(ANACONDA_LAYOUT_INDICATOR(win->priv->layout_indicator));
|
||||
}
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,25 +0,0 @@
|
||||
From 66f30776cdb79ccb26be01ad9cd2e1712fc0170c Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Mon, 9 Mar 2020 21:19:07 +0800
|
||||
Subject: [PATCH] add boot options for dummy
|
||||
|
||||
---
|
||||
pyanaconda/bootloader.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/bootloader.py b/pyanaconda/bootloader.py
|
||||
index 0fe5dd2..f539454 100644
|
||||
--- a/pyanaconda/bootloader.py
|
||||
+++ b/pyanaconda/bootloader.py
|
||||
@@ -1537,7 +1537,7 @@ class GRUB2(GRUB):
|
||||
if blivet.arch.is_aarch64():
|
||||
log.info("check boot args:%s",arg_str)
|
||||
arg_str=re.sub("console=[a-zA-Z0-9,]*","",arg_str)
|
||||
- arg_str+=" smmu.bypassdev=0x1000:0x17 smmu.bypassdev=0x1000:0x15 crashkernel=1024M,high"
|
||||
+ arg_str+=" smmu.bypassdev=0x1000:0x17 smmu.bypassdev=0x1000:0x15 crashkernel=1024M,high video=efifb:off video=VGA-1:640x480-32@60me"
|
||||
else:
|
||||
arg_str+=" quiet crashkernel=512M"
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,19 +1,19 @@
|
||||
diff -uNrp a/pyanaconda/ui/gui/hubs/__init__.py b/pyanaconda/ui/gui/hubs/__init__.py
|
||||
--- a/pyanaconda/ui/gui/hubs/__init__.py 2018-07-25 21:58:20.000000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/hubs/__init__.py 2019-08-12 21:24:15.856000000 +0800
|
||||
@@ -148,7 +148,7 @@ class Hub(GUIObject, common.Hub):
|
||||
# From here on, this Spoke will always exist.
|
||||
spoke = spokeClass(self.data, self.storage, self.payload, self.instclass)
|
||||
spoke.window.set_beta(self.window.get_beta())
|
||||
- spoke.window.set_property("distribution", distributionText().upper())
|
||||
+ spoke.window.set_property("distribution", distributionText())
|
||||
|
||||
# If a spoke is not showable, it is unreachable in the UI. We
|
||||
# might as well get rid of it.
|
||||
diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
--- a/pyanaconda/ui/gui/__init__.py 2018-06-08 05:31:59.000000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/__init__.py 2019-08-12 21:22:19.776000000 +0800
|
||||
@@ -829,7 +829,7 @@ class GraphicalUserInterface(UserInterfa
|
||||
From 853c4c8307c7427e5ee4fb57a2ffdcad1ce9d7f6 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Thu, 18 Jun 2020 22:39:12 +0800
|
||||
Subject: [PATCH] make name not force to uppercase
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/__init__.py | 4 ++--
|
||||
pyanaconda/ui/gui/hubs/__init__.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/welcome.py | 2 +-
|
||||
3 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
index 8c20423..06373d9 100644
|
||||
--- a/pyanaconda/ui/gui/__init__.py
|
||||
+++ b/pyanaconda/ui/gui/__init__.py
|
||||
@@ -839,7 +839,7 @@ class GraphicalUserInterface(UserInterface):
|
||||
self._currentAction.refresh()
|
||||
|
||||
self._currentAction.window.set_beta(not self._isFinal)
|
||||
@ -22,7 +22,7 @@ diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
|
||||
# Set some program-wide settings.
|
||||
settings = Gtk.Settings.get_default()
|
||||
@@ -995,7 +995,7 @@ class GraphicalUserInterface(UserInterfa
|
||||
@@ -1005,7 +1005,7 @@ class GraphicalUserInterface(UserInterface):
|
||||
|
||||
nextAction.initialize()
|
||||
nextAction.window.set_beta(self._currentAction.window.get_beta())
|
||||
@ -31,10 +31,24 @@ diff -uNrp a/pyanaconda/ui/gui/__init__.py b/pyanaconda/ui/gui/__init__.py
|
||||
|
||||
if not nextAction.showable:
|
||||
self._currentAction.window.hide()
|
||||
diff -uNrp a/pyanaconda/ui/gui/spokes/welcome.py b/pyanaconda/ui/gui/spokes/welcome.py
|
||||
--- a/pyanaconda/ui/gui/spokes/welcome.py 2018-10-09 03:00:59.000000000 +0800
|
||||
+++ b/pyanaconda/ui/gui/spokes/welcome.py 2019-08-12 21:23:46.248000000 +0800
|
||||
@@ -238,7 +238,7 @@ class WelcomeLanguageSpoke(LangLocaleHan
|
||||
diff --git a/pyanaconda/ui/gui/hubs/__init__.py b/pyanaconda/ui/gui/hubs/__init__.py
|
||||
index 062e04e..a99e438 100644
|
||||
--- a/pyanaconda/ui/gui/hubs/__init__.py
|
||||
+++ b/pyanaconda/ui/gui/hubs/__init__.py
|
||||
@@ -145,7 +145,7 @@ class Hub(GUIObject, common.Hub):
|
||||
# From here on, this Spoke will always exist.
|
||||
spoke = spokeClass(self.data, self.storage, self.payload)
|
||||
spoke.window.set_beta(self.window.get_beta())
|
||||
- spoke.window.set_property("distribution", distributionText().upper())
|
||||
+ spoke.window.set_property("distribution", distributionText())
|
||||
|
||||
# If a spoke is not showable, it is unreachable in the UI. We
|
||||
# might as well get rid of it.
|
||||
diff --git a/pyanaconda/ui/gui/spokes/welcome.py b/pyanaconda/ui/gui/spokes/welcome.py
|
||||
index 4f1bfbc..3373f1d 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/welcome.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/welcome.py
|
||||
@@ -241,7 +241,7 @@ class WelcomeLanguageSpoke(StandaloneSpoke, LangLocaleHandler):
|
||||
welcomeLabel = self.builder.get_object("welcomeLabel")
|
||||
|
||||
welcomeLabel.set_text(_("WELCOME TO %(name)s %(version)s.") %
|
||||
@ -43,3 +57,6 @@ diff -uNrp a/pyanaconda/ui/gui/spokes/welcome.py b/pyanaconda/ui/gui/spokes/welc
|
||||
|
||||
# Retranslate the language (filtering) entry's placeholder text
|
||||
languageEntry = self.builder.get_object("languageEntry")
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
From 638d318636727fd20c48d354f21ff67c3cf28238 Mon Sep 17 00:00:00 2001
|
||||
From: fengtao <fengtao40@huawei.com>
|
||||
Date: Wed, 8 Jan 2020 09:57:37 +0800
|
||||
From aa21df647d18390124379026dbaf99741d336875 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 10:43:24 +0800
|
||||
Subject: [PATCH] modify arguments parsing
|
||||
|
||||
---
|
||||
@ -8,10 +8,10 @@ Subject: [PATCH] modify arguments parsing
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pyanaconda/argument_parsing.py b/pyanaconda/argument_parsing.py
|
||||
index b7b1777..1a7f418 100644
|
||||
index 6b2f40f..ce29587 100644
|
||||
--- a/pyanaconda/argument_parsing.py
|
||||
+++ b/pyanaconda/argument_parsing.py
|
||||
@@ -588,7 +588,7 @@ def getArgumentParser(version_string, boot_cmdline=None):
|
||||
@@ -592,7 +592,7 @@ def getArgumentParser(version_string, boot_cmdline=None):
|
||||
|
||||
# some defaults change based on cmdline flags
|
||||
if boot_cmdline is not None:
|
||||
@ -21,5 +21,5 @@ index b7b1777..1a7f418 100644
|
||||
|
||||
return ap
|
||||
--
|
||||
1.8.3.1
|
||||
2.23.0
|
||||
|
||||
55
modify-default-timezone.patch
Normal file
55
modify-default-timezone.patch
Normal file
@ -0,0 +1,55 @@
|
||||
From 59a4b9b04388e327e135f3ab9893698e2b3f5a5d Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 11:44:31 +0800
|
||||
Subject: [PATCH] modify default timezone
|
||||
|
||||
---
|
||||
pyanaconda/modules/timezone/installation.py | 4 ++--
|
||||
pyanaconda/modules/timezone/timezone.py | 2 +-
|
||||
pyanaconda/ui/gui/spokes/datetime_spoke.py | 2 +-
|
||||
3 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/modules/timezone/installation.py b/pyanaconda/modules/timezone/installation.py
|
||||
index 6383df1..9c6ae40 100644
|
||||
--- a/pyanaconda/modules/timezone/installation.py
|
||||
+++ b/pyanaconda/modules/timezone/installation.py
|
||||
@@ -63,8 +63,8 @@ class ConfigureTimezoneTask(Task):
|
||||
if not is_valid_timezone(self._timezone):
|
||||
# this should never happen, but for pity's sake
|
||||
log.warning("Timezone %s set in kickstart is not valid, "
|
||||
- "falling back to default (America/New_York).", self._timezone)
|
||||
- self._timezone = "America/New_York"
|
||||
+ "falling back to default (Asia/Shanghai).", self._timezone)
|
||||
+ self._timezone = "Asia/Shanghai"
|
||||
|
||||
def _make_timezone_symlink(self):
|
||||
"""Create the symlink that actually defines timezone."""
|
||||
diff --git a/pyanaconda/modules/timezone/timezone.py b/pyanaconda/modules/timezone/timezone.py
|
||||
index 0678072..db1cd18 100644
|
||||
--- a/pyanaconda/modules/timezone/timezone.py
|
||||
+++ b/pyanaconda/modules/timezone/timezone.py
|
||||
@@ -40,7 +40,7 @@ class TimezoneService(KickstartService):
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.timezone_changed = Signal()
|
||||
- self._timezone = "America/New_York"
|
||||
+ self._timezone = "Asia/Shanghai"
|
||||
|
||||
self.is_utc_changed = Signal()
|
||||
self._is_utc = False
|
||||
diff --git a/pyanaconda/ui/gui/spokes/datetime_spoke.py b/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
index 00b1bd9..f01d245 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/datetime_spoke.py
|
||||
@@ -65,7 +65,7 @@ SERVER_POOL = 1
|
||||
SERVER_WORKING = 2
|
||||
SERVER_USE = 3
|
||||
|
||||
-DEFAULT_TZ = "America/New_York"
|
||||
+DEFAULT_TZ = "Asia/Shanghai"
|
||||
|
||||
SPLIT_NUMBER_SUFFIX_RE = re.compile(r'([^0-9]*)([-+])([0-9]+)')
|
||||
|
||||
--
|
||||
2.23.0
|
||||
|
||||
25
modify-interface-is-extended-in-Chinese-mode.patch
Normal file
25
modify-interface-is-extended-in-Chinese-mode.patch
Normal file
@ -0,0 +1,25 @@
|
||||
From 1999c1bd693ee187cc699fd1f1d4ac77086373b9 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 09:26:00 +0800
|
||||
Subject: [PATCH] modify interface is extended in Chinese mode
|
||||
|
||||
---
|
||||
po/zh_CN.po | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index be8cefe..7ee5511 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -6429,7 +6429,7 @@ msgstr "搜索方式(_B):"
|
||||
|
||||
#: pyanaconda/ui/gui/spokes/advanced_storage.glade:153
|
||||
msgid "Port / Target / LUN #"
|
||||
-msgstr "端口 / 目标 / 逻辑单位数标示符 (LUN #) "
|
||||
+msgstr "端口 / 目标 / LUN # "
|
||||
|
||||
#: pyanaconda/ui/gui/spokes/advanced_storage.glade:154
|
||||
msgid "Target WWID"
|
||||
--
|
||||
2.23.0
|
||||
|
||||
@ -1,14 +1,15 @@
|
||||
From 1ce4ab95a64e64b7b4eab52c2172149816900572 Mon Sep 17 00:00:00 2001
|
||||
Date: Thu, 6 Feb 2020 12:08:08 +0800
|
||||
From 343751258b3a4b3e21cf52add5a9ddf600065835 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 11:48:25 +0800
|
||||
Subject: [PATCH] modify network hostname dot illegal
|
||||
|
||||
---
|
||||
anaconda-29.24.7/pyanaconda/core/regexes.py | 2 +-
|
||||
anaconda-29.24.7/pyanaconda/network.py | 2 +-
|
||||
pyanaconda/core/regexes.py | 2 +-
|
||||
pyanaconda/network.py | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/core/regexes.py b/pyanaconda/core/regexes.py
|
||||
index 1f1da07..544d40e 100644
|
||||
index 63ab668..f86e403 100644
|
||||
--- a/pyanaconda/core/regexes.py
|
||||
+++ b/pyanaconda/core/regexes.py
|
||||
@@ -103,7 +103,7 @@ IPV4_NETMASK_WITH_ANCHORS = re.compile("^" + IPV4_NETMASK_WITHOUT_ANCHORS + "$")
|
||||
@ -21,18 +22,18 @@ index 1f1da07..544d40e 100644
|
||||
# URL Hostname
|
||||
# This matches any hostname, IPv4 literal or properly encased IPv6 literal
|
||||
diff --git a/pyanaconda/network.py b/pyanaconda/network.py
|
||||
index 02dba66..1cde6d2 100644
|
||||
index 127a1bd..30cf2af 100644
|
||||
--- a/pyanaconda/network.py
|
||||
+++ b/pyanaconda/network.py
|
||||
@@ -121,7 +121,7 @@ def sanityCheckHostname(hostname):
|
||||
@@ -119,7 +119,7 @@ def is_valid_hostname(hostname, local=False):
|
||||
return (False, _("Host names can only contain the characters 'a-z', "
|
||||
"'A-Z', '0-9', '-', or '.', parts between periods "
|
||||
"must contain something being 63 or fewer "
|
||||
- "characters and cannot start or end with '-'."))
|
||||
+ "characters and cannot start or end with '.'and'-'."))
|
||||
"must contain something being 63 or fewer "
|
||||
- "characters and cannot start or end with '-'."))
|
||||
+ "characters and cannot start or end with '.' and '-'."))
|
||||
|
||||
return (True, "")
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
2.23.0
|
||||
|
||||
16
openeuler.conf
Normal file
16
openeuler.conf
Normal file
@ -0,0 +1,16 @@
|
||||
# Anaconda configuration file for openEuler
|
||||
|
||||
[Product]
|
||||
product_name = openEuler
|
||||
|
||||
[Bootloader]
|
||||
efi_dir = openEuler
|
||||
|
||||
[Payload]
|
||||
enable_closest_mirror = True
|
||||
|
||||
[User Interface]
|
||||
blivet_gui_supported = False
|
||||
|
||||
[License]
|
||||
eula = "/usr/share/openEuler-release/EULA"
|
||||
28
remove-vender-issue-in-netdev.patch
Normal file
28
remove-vender-issue-in-netdev.patch
Normal file
@ -0,0 +1,28 @@
|
||||
From b896b694238389a85539f60cab6ee41ab04c4f29 Mon Sep 17 00:00:00 2001
|
||||
From: t_feng <fengtao40@huawei.com>
|
||||
Date: Fri, 19 Jun 2020 10:25:20 +0800
|
||||
Subject: [PATCH] remove vender issue in netdev
|
||||
|
||||
---
|
||||
pyanaconda/ui/gui/spokes/network.py | 5 ++---
|
||||
1 file changed, 2 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
|
||||
index 1318e17..e906f9e 100644
|
||||
--- a/pyanaconda/ui/gui/spokes/network.py
|
||||
+++ b/pyanaconda/ui/gui/spokes/network.py
|
||||
@@ -782,9 +782,8 @@ class NetworkControlBox(GObject.GObject):
|
||||
unplugged)
|
||||
|
||||
if device:
|
||||
- title += '\n<span size="small">%s %s</span>' % \
|
||||
- (escape_markup(device.get_vendor() or ""),
|
||||
- escape_markup(device.get_product() or ""))
|
||||
+ title += '\n<span size="small">%s</span>' % \
|
||||
+ (escape_markup(device.get_product() or ""))
|
||||
return title
|
||||
|
||||
def refresh_ui(self, state=None):
|
||||
--
|
||||
2.23.0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user