-
Notifications
You must be signed in to change notification settings - Fork 197
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: update compliance reconcile tests
- Loading branch information
1 parent
ae04999
commit d7d4763
Showing
3 changed files
with
133 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
119 changes: 119 additions & 0 deletions
119
pkg/compliance/testdata/fixture/configAuditReportUpdate.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
{ | ||
"apiVersion": "aquasecurity.github.io/v1alpha1", | ||
"kind": "ConfigAuditReport", | ||
"metadata": { | ||
"creationTimestamp": "2022-02-24T09:13:26Z", | ||
"generation": 1, | ||
"labels": { | ||
"plugin-config-hash": "78bf5dccc5", | ||
"resource-spec-hash": "65c6f56fd9", | ||
"starboard.resource.kind": "Pod", | ||
"starboard.resource.name": "rss-site", | ||
"starboard.resource.namespace": "default" | ||
}, | ||
"name": "pod-rss-site", | ||
"namespace": "default", | ||
"ownerReferences": [ | ||
{ | ||
"apiVersion": "v1", | ||
"blockOwnerDeletion": false, | ||
"controller": true, | ||
"kind": "Pod", | ||
"name": "rss-site", | ||
"uid": "5cbf85d2-09f5-458a-9499-c65e71ff7610" | ||
} | ||
], | ||
"resourceVersion": "1153705", | ||
"uid": "88a1ddd4-1f13-4222-9649-034f1a251458" | ||
}, | ||
"report": { | ||
"checks": [ | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV014", | ||
"messages": [ | ||
"Container 'front-end' of Pod 'rss-site' should set 'securityContext.readOnlyRootFilesystem' to true" | ||
], | ||
"severity": "danger", | ||
"success": true | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV014", | ||
"messages": [ | ||
"Container 'rss-reader' of Pod 'rss-site' should set 'securityContext.readOnlyRootFilesystem' to true" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV013", | ||
"messages": [ | ||
"Container 'front-end' of Pod 'rss-site' should specify an image tag" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV013", | ||
"messages": [ | ||
"Container 'rss-reader' of Pod 'rss-site' should specify an image tag" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
} | ||
], | ||
"containerChecks": {}, | ||
"podChecks": [ | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV014", | ||
"messages": [ | ||
"Container 'front-end' of Pod 'rss-site' should set 'securityContext.readOnlyRootFilesystem' to true" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV014", | ||
"messages": [ | ||
"Container 'rss-reader' of Pod 'rss-site' should set 'securityContext.readOnlyRootFilesystem' to true" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV013", | ||
"messages": [ | ||
"Container 'front-end' of Pod 'rss-site' should specify an image tag" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
}, | ||
{ | ||
"category": "Security", | ||
"checkID": "KSV013", | ||
"messages": [ | ||
"Container 'rss-reader' of Pod 'rss-site' should specify an image tag" | ||
], | ||
"severity": "danger", | ||
"success": false | ||
} | ||
], | ||
"scanner": { | ||
"name": "Conftest", | ||
"vendor": "Open Policy Agent", | ||
"version": "v0.28.2" | ||
}, | ||
"summary": { | ||
"dangerCount": 4, | ||
"passCount": 0, | ||
"warningCount": 0 | ||
}, | ||
"updateTimestamp": "2022-02-24T09:13:26Z" | ||
} | ||
} |