CMP-3969: Fix panic issue when deleting a scan with invalid storage size
Fix panic issue when deleting a scan with invalid storage size
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: xiaojiey
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [xiaojiey]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
@xiaojiey: This pull request references CMP-3969 which is a valid jira issue.
Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.21.0" version, but no target version was set.
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-6726366a502651447d386fee3a4c736d2a667620
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-15a3b2064bfb20c8b8594d44cb6ac44a83783052
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-fae2907259dbdee5003230202ba834592baf2f64
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-465530e6110de5756d848de6b5d06684de764a71
Pre-merge verificartion PASS with CO installed from this PR + OCP 4.20:
Test case OCP-43072 run on the cluster without the defer step. Compliancesuite is created directly in this test case. Following compliancesuite was created:
apiVersion: compliance.openshift.io/v1alpha1
kind: ComplianceSuite
metadata:
name: worker-compliancesuiteubsh8thrl0
namespace: openshift-compliance
spec:
autoApplyRemediations: false
scans:
- name: worker-scanihr5afxz13
profile: xccdf_org.ssgproject.content_profile_coreos-ncp
scanType: Node
content: ssg-rhcos4-ds.xml
contentImage: relatedImageProfile
nodeSelector:
node-role.kubernetes.io/worker: ""
rawResultStorage:
nodeSelector:
node-role.kubernetes.io/master: ""
size: 1B
tolerations:
- effect: NoSchedule
key: node-role.kubernetes.io/master
operator: Exists
- effect: NoExecute
key: node.kubernetes.io/not-ready
operator: Exists
tolerationSeconds: 300
- effect: NoExecute
key: node.kubernetes.io/unreachable
operator: Exists
tolerationSeconds: 300
- effect: NoSchedule
key: node.kubernetes.io/memory-pressure
operator: Exists
Compliance suite and scan resulted in Error, which is expected and after got deleted successfully:
$ oc get suite
NAME PHASE RESULT
worker-compliancesuiteubsh8thrl0 DONE ERROR
$ oc get scan
NAME PHASE RESULT
worker-scanihr5afxz13 DONE ERROR
$ oc delete suite worker-compliancesuiteubsh8thrl0
compliancesuite.compliance.openshift.io "worker-compliancesuiteubsh8thrl0" deleted
$ oc get scan
No resources found in openshift-compliance namespace.
$ oc get suite
No resources found in openshift-compliance namespace.
/retest-required
@xiaojiey: This pull request references CMP-3969 which is a valid jira issue.
Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.21.0" version, but no target version was set.
This pull request references CMP-3829 which is a valid jira issue.
Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.21.0" version, but no target version was set.
In response to this:
Fix panic issue when deleting a scan with invalid storage size
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-4051ff52b1f50460f3766b9ced328e3c4abb6be0
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-8f80c028bdb5990bcccb7dba2ad4e19fae0afe9b
/retest
:robot: To deploy this PR, run the following command:
make catalog-deploy CATALOG_IMG=ghcr.io/complianceascode/compliance-operator-catalog:993-5b5c80a5496e0fa09542014a4dd0341a36095ebe
/retest
/retest-required
/retest
@xiaojiey: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:
| Test name | Commit | Details | Required | Rerun command |
|---|---|---|---|---|
| ci/prow/e2e-aws-serial | 5b5c80a5496e0fa09542014a4dd0341a36095ebe | link | true | /test e2e-aws-serial |
| ci/prow/e2e-rosa | 5b5c80a5496e0fa09542014a4dd0341a36095ebe | link | true | /test e2e-rosa |
Full PR test history. Your PR dashboard.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.