Uploaded image for project: 'Insights Experiences'
  1. Insights Experiences
  2. HMS-3072

Stop the Conversion Task when convert2rhel.ini was edited

XMLWordPrintable

      Goal: 

      • In case the customer had convert2rhel installed prior to executing the Pre-conversion analysis or the Conversion Task and they created/edited a config file for convert2rhel (convert2rhel.ini), the Tasks shall not proceed with the convert2rhel execution.
      • The reason is that the config file is currently used only for entering RHSM credentials. And when convert2rhel find any credentials in the ini file, it uses them for (re-)registration to RHSM. But when running convert2rhel through the Insights Tasks, we can't let convert2rhel re-register the system because it would lead to a different RHSM UUID which is used as a host identifier by Insights and with that the rhcd communication between the host and Insights would break.

      Acceptance Criteria:

      • Before the conversion script (HMS-2015) calls convert2rhel, it looks at whether the /etc/convert2rhel.ini has been edited or whether /.convert2rhel.ini exists
        • If either is true, stop the conversion with an error message telling the user through Insights Tasks UI that they need to either remove the ini file(s)
        • Checking the /etc/convert2rhel.ini for edits can be done by `rpm -Va` and looking for '5' marking MD5 hash mismatch
      • This check is added also to the pre-conversion analysis script (HMS-2892)

            awaltlov@redhat.com Andrea Waltlova
            mbocek@redhat.com Michal Bocek
            Martin Litwora Martin Litwora
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: