fix tags so that they are rendered to string directly from struct #5483
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Rick Marry rick.marry@gmail.com
π© Description: What code changed, and why?
this fixes bug #5399
This PR fixes a bug where control tags are not making in with the profile as it's stored in elasticsearch
In order for this bug fix to work, the profiles that are currently in elasticsearch need to be removed and compliance-service needs to be restarted. The removal and restart will cause the profiles to be re-ingested into elastic and the control tags will now be present. From that point forward, any inspec reports that are sent up to automate will carry with them, the control tags for each respective profile.
*N.B. already ingested reports will not ever have the tags for the controls as they are decorated with them upon ingestion which has already happened prior to this fix
βοΈ Related Resources
π Definition of Done
π How to Build and Test the Change
From within hab studio:
rebuild components/compliance-service
Get a profile that has some tags like
CIS Docker Benchmark Profile
Create a scan job and select this
CIS Docker Benchmark Profile
profileRun your newly created scan job in automate
Once it completes its run, whenever you export the node or call
reporting/reports/id/:id
for the job that you have just run and navigate to profiles->controls section of the json output, in each control you should now see its respective control tags.You can also add these newly present control tags to your filter when using compliance.. in the filter text entry box, filter on
Control Tag
, you should see some of the available tags appear, which you may now select. Prior to this bug fix, nothing would be suggested forControl-Tag
and we were not able to use them to filter as they did not exist in reports prior to this.β Checklist
All PRs must tick these:
With occasional exceptions, all PRs from Progress employees must tick these:
make spell
in any component directory)All PRs from Progress employees should tick these if appropriate:
Please add a note next to any checkbox above if you are NOT ticking it.
π· Screenshots, if applicable