diff --git a/repos/system_upgrade/common/actors/checkfips/actor.py b/repos/system_upgrade/common/actors/checkfips/actor.py index bd09b1b9e2..05472c05b8 100644 --- a/repos/system_upgrade/common/actors/checkfips/actor.py +++ b/repos/system_upgrade/common/actors/checkfips/actor.py @@ -41,7 +41,7 @@ def process(self): reporting.ExternalLink(url=fips_7to8_steps_docs_url, title='Planning an upgrade from RHEL 7 to RHEL 8') ]) - else: + elif version.get_target_major_version() == '9': # FIXME(mhecko): We include these files manually as they are not included automatically when the fips # module is used due to a bug in dracut. This code should be removed, once the dracut bug is resolved. # See https://bugzilla.redhat.com/show_bug.cgi?id=2176560 @@ -53,3 +53,6 @@ def process(self): ] self.produce(UpgradeInitramfsTasks(include_files=fips_required_initramfs_files, include_dracut_modules=[DracutModule(name='fips')])) + elif version.get_target_major_version() == '10': + # TODO(mmatuska): What to do with FIPS? + pass diff --git a/repos/system_upgrade/common/actors/checksaphana/libraries/checksaphana.py b/repos/system_upgrade/common/actors/checksaphana/libraries/checksaphana.py index 7cd83de866..6dad9cf36c 100644 --- a/repos/system_upgrade/common/actors/checksaphana/libraries/checksaphana.py +++ b/repos/system_upgrade/common/actors/checksaphana/libraries/checksaphana.py @@ -7,7 +7,8 @@ # Supported architectures for upgrades with SAP HANA to RHEL 'X' SAP_HANA_SUPPORTER_ARCHS = { '8': [architecture.ARCH_X86_64], - '9': [architecture.ARCH_X86_64, architecture.ARCH_PPC64LE] + '9': [architecture.ARCH_X86_64, architecture.ARCH_PPC64LE], + # TODO(mmatuska): what arches are supported for sap hana for 9to10? } SAP_HANA_MINIMAL_MAJOR_VERSION = 2 diff --git a/repos/system_upgrade/common/actors/opensshpermitrootlogincheck/actor.py b/repos/system_upgrade/common/actors/opensshpermitrootlogincheck/actor.py index 7a49622f4f..113bff4fa1 100644 --- a/repos/system_upgrade/common/actors/opensshpermitrootlogincheck/actor.py +++ b/repos/system_upgrade/common/actors/opensshpermitrootlogincheck/actor.py @@ -50,6 +50,9 @@ def process(self): self.process7to8(config) elif get_source_major_version() == '8': self.process8to9(config) + elif get_source_major_version() == '9': + # TODO(mmatuska): no-op? + pass else: api.current_logger().warning('Unknown source major version: {} (expecting 7 or 8)' .format(get_source_major_version())) diff --git a/repos/system_upgrade/common/actors/openssl/checkopensslconf/libraries/checkopensslconf.py b/repos/system_upgrade/common/actors/openssl/checkopensslconf/libraries/checkopensslconf.py index 06a30fa102..53e803b2ea 100644 --- a/repos/system_upgrade/common/actors/openssl/checkopensslconf/libraries/checkopensslconf.py +++ b/repos/system_upgrade/common/actors/openssl/checkopensslconf/libraries/checkopensslconf.py @@ -5,8 +5,11 @@ from leapp.models import DistributionSignedRPM, TrackedFilesInfoSource DEFAULT_OPENSSL_CONF = '/etc/pki/tls/openssl.cnf' -URL_8_CRYPTOPOLICIES = 'https://red.ht/rhel-8-system-wide-crypto-policies' -URL_9_CRYPTOPOLICIES = 'https://red.ht/rhel-9-system-wide-crypto-policies' +URL_CRYPTOPOLICIES = { + '8': 'https://red.ht/rhel-8-system-wide-crypto-policies', + '9': 'https://red.ht/rhel-9-system-wide-crypto-policies', + '10': 'https://red.ht/rhel-10-system-wide-crypto-policies', # TODO actually make the url +} def check_ibmca(): @@ -70,7 +73,7 @@ def check_default_openssl(): if not _is_openssl_modified(): return - crypto_url = URL_8_CRYPTOPOLICIES if version.get_target_major_version == '8' else URL_9_CRYPTOPOLICIES + crypto_url = URL_CRYPTOPOLICIES[version.get_target_major_version()] # TODO(pstodulk): Needs in future some rewording, as OpenSSL engines are # deprecated since "RHEL 8" and people should use OpenSSL providers instead. diff --git a/repos/system_upgrade/common/actors/storagescanner/tests/files/mdstat b/repos/system_upgrade/common/actors/storagescanner/tests/files/mdstat new file mode 100644 index 0000000000..09842070d3 --- /dev/null +++ b/repos/system_upgrade/common/actors/storagescanner/tests/files/mdstat @@ -0,0 +1,15 @@ +Personalities : [raid1] [raid6] [raid5] [raid4] +md1 : active raid1 sdb2[1] sda2[0] + 136448 blocks [2/2] [UU] + +md0 : active raid1 sdb1[1] sda1[0] + 16787776 blocks [2/2] [UU] + +md127 : active raid5 sdh1[6] sdg1[4] sdf1[3] sde1[2] sdd1[1] sdc1[0] + 1464725760 blocks level 5, 64k chunk, algorithm 2 [6/5] [UUUUU_] + [==>..................] recovery = 12.6% (37043392/292945152) finish=127.5min speed=33440K/sec + +md_d0 : inactive sdd1[0](S) sdf1[3](S) sde1[2](S) sdb1[1](S) + 3907039744 blocks + +unused devices: diff --git a/repos/system_upgrade/common/actors/systemd/repairsystemdsymlinks/libraries/repairsystemdsymlinks.py b/repos/system_upgrade/common/actors/systemd/repairsystemdsymlinks/libraries/repairsystemdsymlinks.py index 884b001e9a..f8e424f6be 100644 --- a/repos/system_upgrade/common/actors/systemd/repairsystemdsymlinks/libraries/repairsystemdsymlinks.py +++ b/repos/system_upgrade/common/actors/systemd/repairsystemdsymlinks/libraries/repairsystemdsymlinks.py @@ -6,18 +6,12 @@ from leapp.libraries.stdlib import api, CalledProcessError, run from leapp.models import SystemdBrokenSymlinksSource, SystemdBrokenSymlinksTarget, SystemdServicesInfoSource -_INSTALLATION_CHANGED_EL8 = ['rngd.service', 'sysstat.service'] -_INSTALLATION_CHANGED_EL9 = [] - -def _get_installation_changed_units(): - version = get_target_major_version() - if version == '8': - return _INSTALLATION_CHANGED_EL8 - if version == '9': - return _INSTALLATION_CHANGED_EL9 - - return [] +_INSTALLATION_CHANGED = { + '8': ['rngd.service', 'sysstat.service'], + '9': [], + '10': [], +} def _service_enabled_source(service_info, name): @@ -49,7 +43,7 @@ def _handle_newly_broken_symlinks(symlinks, service_info): def _handle_bad_symlinks(service_files): - install_changed_units = _get_installation_changed_units() + install_changed_units = _INSTALLATION_CHANGED[get_target_major_version()] potentially_bad = [s for s in service_files if s.name in install_changed_units] for unit_file in potentially_bad: diff --git a/repos/system_upgrade/common/libraries/rhui.py b/repos/system_upgrade/common/libraries/rhui.py index b2b906c3eb..d1e1fa332f 100644 --- a/repos/system_upgrade/common/libraries/rhui.py +++ b/repos/system_upgrade/common/libraries/rhui.py @@ -554,6 +554,7 @@ def mk_rhui_setup(clients=None, leapp_pkg='', mandatory_files=None, optional_fil } +# TODO(mmatuska) deprecate or adjust for 9to10? def get_upg_path(): """ Get upgrade path in specific string format