Skip to content

Commit 38c34c6

Browse files
committed
Utilize get_target_major_version in no enabled target repositories report
Signed-off-by: Andrea Waltlova <[email protected]>
1 parent f5d50f7 commit 38c34c6

File tree

1 file changed

+3
-3
lines changed
  • repos/system_upgrade/common/actors/targetuserspacecreator/libraries

1 file changed

+3
-3
lines changed

repos/system_upgrade/common/actors/targetuserspacecreator/libraries/userspacegen.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -812,6 +812,7 @@ def gather_target_repositories(context, indata):
812812
missing_custom_repoids.append(custom_repo.repoid)
813813
api.current_logger().debug("Gathered target repositories: {}".format(', '.join(target_repoids)))
814814
if not target_repoids:
815+
target_major_version = get_target_major_version()
815816
reporting.create_report([
816817
reporting.Title('There are no enabled target repositories'),
817818
reporting.Summary(
@@ -833,8 +834,7 @@ def gather_target_repositories(context, indata):
833834
' Finally, verify that the "/etc/leapp/files/repomap.json" file is up-to-date.'
834835
).format(version=api.current_actor().configuration.version.target)),
835836
reporting.ExternalLink(
836-
# TODO: How to handle different documentation links for each version?
837-
url='https://red.ht/preparing-for-upgrade-to-rhel8',
837+
url='https://red.ht/preparing-for-upgrade-to-rhel{}'.format(target_major_version),
838838
title='Preparing for the upgrade'),
839839
reporting.RelatedResource("file", "/etc/leapp/files/repomap.json"),
840840
reporting.RelatedResource("file", "/etc/yum.repos.d/")
@@ -854,7 +854,7 @@ def gather_target_repositories(context, indata):
854854
reporting.Groups([reporting.Groups.INHIBITOR]),
855855
reporting.Severity(reporting.Severity.HIGH),
856856
reporting.ExternalLink(
857-
# TODO: How to handle different documentation links for each version?
857+
# NOTE: Article covers both RHEL 7 to RHEL 8 and RHEL 8 to RHEL 9
858858
url='https://access.redhat.com/articles/4977891',
859859
title='Customizing your Red Hat Enterprise Linux in-place upgrade'),
860860
reporting.Remediation(hint=(

0 commit comments

Comments
 (0)