-
Sub-task
-
Resolution: Unresolved
-
Undefined
-
None
-
None
-
None
-
False
-
False
-
-
1
-
Testable
The parent issue RHELC-1106 has the label that triggered autocreation of this subtask to track the relative story point estimation for the integration test part of the issue.
The parent issue description at the time of creation of this issue was:
Messages need to be usable by third party tools, not just convert2rhel. Specifically, satellite will need the ability to construct messages in a similar manner to how insights does. To do that, we need convert2rhel to provide message templates to satellite that mirror the message templates which are hosted in insights.
Doing this means that we need to make use of the templates inside of convert2rhel as well.
Acceptance Criteria
- In convert2rhel.action.report.summary()
- Where we construct the message from the four fields, title, description, diagnosis, and remediation,.use jinja2 to template diagnosis and remediation.
-
-
- After templating, the string should be valid markdown but we will just display the plain text. It's insights, satellite and other external tools that should be able to rely on it being markdown.
- Use the variables that we added in https://issues.redhat.com/browse/RHELC-1091to render the templates
-
- In the action plugins:
- For each Action, we need to look at the diagnosis and remediation fields and make those into jinja2 templates.
- All variables presently used to construct those fields should have been added to variables by RHELC-1091 (but if they weren't, then do so here).
- There should not be dynamic data used to construct the title and description fields. If so, then rectify that here by making them generic and putting the dynamic data into diagnosis.
- Add python-jinja2 as a dependency to convert2rhel in the rpm spec file(s) (in the git repo and in distgit).
- We don't have dependencies listed in setup.py at the time of writing. If we add that, we will need to add the jinja2 dep there as well.
- Update https://issues.redhat.com/browse/RHELC-1093 to reflect whether stretch goals here were implemented or not.
Stretch Goals:
If these are not done as part of this ticket, they will be done as part of https://issues.redhat.com/browse/RHELC-1091
- Move messages into a json file. Format is:
- a dictionary keyed on ACTION_ID:MESSAGE_ID
- Value is a set of three fields that we will use to construct the convert2rhel messages: title, description, diagnosis, remediation. convet2rhel displays those as a single message.
- convert2rhel code changes
- In convert2rhel.action.report.summary()
- read the messages from the json file
- In convert2rhel.action.report.summary()