Bump the gomodupdates group across 1 directory with 4 updates (#1095) #2668
5 fail, 18 pass in 6h 31m 16s
8 files 8 suites 6h 31m 16s ⏱️
23 tests 18 ✅ 0 💤 5 ❌
184 runs 171 ✅ 0 💤 13 ❌
Results for commit 0f48aa6.
Annotations
Check warning on line 0 in go.mondoo.com/mondoo-operator/tests/integration
github-actions / Test Results
3 out of 8 runs failed: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers (go.mondoo.com/mondoo-operator/tests/integration)
integration-tests-gke-1.27.xml [took 2m 4s]
integration-tests-gke-1.28.xml [took 1m 55s]
integration-tests-gke-1.29.xml [took 2m 24s]
Raw output
Failed
=== RUN TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
2024-04-28T23:16:52.452Z INFO utils/audit_config.go:71 Using image ghcr.io/mondoohq/mondoo-operator/cnspec:latest-rootless for mondoo-client
2024-04-28T23:16:52.452Z DEBUG utils/executor.go:271 Running command: kubectl run -n default nginx --image nginx -l app.kubernetes.io/name=nginx
2024-04-28T23:16:52.716Z DEBUG utils/executor.go:271 Running command: kubectl run -n default redis --image redis -l app.kubernetes.io/name=redis
2024-04-28T23:16:59.367Z INFO integration/audit_config_base_suite.go:252 Create an audit config that enables only workloads scanning.
2024-04-28T23:16:59.648Z INFO integration/audit_config_base_suite.go:262 Make sure the Mondoo k8s container image scan CronJob is created.
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_namespace_test.go:96
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/rule-evaluator@1f43e65c4c12 should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_namespace_test.go:96
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/operator@007b1eb9afba should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_namespace_test.go:96
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/prometheus@4e54e60a9de0 should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_namespace_test.go:96
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/config-reloader@5a852aebfbd9 should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_namespace_test.go:96
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/gke-distroless/bash@17d23aa1d2cc should be the default k8s policies
2024-04-28T23:19:11.153Z INFO installer/installer.go:212 gathering all logs from the test
2024-04-28T23:19:11.153Z INFO utils/k8s_helper.go:256 Gathering logs for all pods in namespace some-namespace
2024-04-28T23:19:11.251Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/some-namespace_mondoo-client-containers-scan-28572438-w8mgf_1714346351.log
2024-04-28T23:19:11.416Z INFO utils/k8s_helper.go:267 Gathering pod describe for all pods in namespace some-namespace
2024-04-28T23:19:11.482Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/describe_some-namespace_1714346351.log
2024-04-28T23:19:11.482Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n some-namespace mondoo-client-containers-scan-28572438-w8mgf
2024-04-28T23:19:11.884Z DEBUG utils/executor.go:271 Running command: kubectl get cronjob -o yaml -n some-namespace mondoo-client-containers-scan
2024-04-28T23:19:12.210Z DEBUG utils/executor.go:271 Running command: kubectl get mondooauditconfig -o yaml -n some-namespace mondoo-client
2024-04-28T23:19:12.423Z INFO utils/k8s_helper.go:318 Gathering events in namespace "some-namespace"
2024-04-28T23:19:12.424Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/events_some-namespace_1714346352.log
2024-04-28T23:19:12.424Z DEBUG utils/executor.go:271 Running command: kubectl get events -n some-namespace
2024-04-28T23:19:12.774Z INFO installer/installer.go:212 gathering all logs from the test
2024-04-28T23:19:12.774Z INFO utils/k8s_helper.go:256 Gathering logs for all pods in namespace mondoo-operator
2024-04-28T23:19:12.865Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/mondoo-operator_mondoo-operator-controller-manager-8646559c78-fd5m6_1714346352.log
2024-04-28T23:19:12.961Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/mondoo-operator_mondoo-operator-controller-manager-8646559c78-fd5m6_previous_1714346352.log
2024-04-28T23:19:13.031Z DEBUG utils/executor.go:271 Running command: kubectl -n mondoo-operator logs mondoo-operator-controller-manager-8646559c78-fd5m6 -c manager
2024-04-28T23:19:13.360Z INFO utils/k8s_helper.go:267 Gathering pod describe for all pods in namespace mondoo-operator
2024-04-28T23:19:13.427Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/describe_mondoo-operator_1714346353.log
2024-04-28T23:19:13.427Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-operator-controller-manager-8646559c78-fd5m6
2024-04-28T23:19:13.746Z DEBUG utils/executor.go:271 Running command: kubectl get deployment -o yaml -n mondoo-operator mondoo-operator-controller-manager
2024-04-28T23:19:14.141Z INFO utils/k8s_helper.go:318 Gathering events in namespace "mondoo-operator"
2024-04-28T23:19:14.142Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigCustomNamespaceSuite/TestReconcile_Containers/events_mondoo-operator_1714346354.log
2024-04-28T23:19:14.142Z DEBUG utils/executor.go:271 Running command: kubectl get events -n mondoo-operator
2024-04-28T23:19:14.676Z INFO utils/k8s_helper.go:351 Resource k8s.mondoo.com/v1alpha2, Kind=MondooAuditConfig some-namespace/mondoo-client deleted.
2024-04-28T23:19:14.676Z INFO installer/installer.go:192 Deleted MondooAuditConfig some-namespace/mondoo-client.
2024-04-28T23:19:14.825Z INFO integration/audit_config_base_suite.go:117 Waiting for cleanup of the test cluster.
2024-04-28T23:19:15.154Z INFO integration/audit_config_base_suite.go:142 Cleanup done. Cluster should be good to go for the next test.
2024-04-28T23:19:15.489Z DEBUG utils/executor.go:271 Running command: kubectl delete pods -n default --all --wait
--- FAIL: TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers (144.27s)
Check warning on line 0 in go.mondoo.com/mondoo-operator/tests/integration
github-actions / Test Results
3 out of 8 runs failed: TestAuditConfigCustomNamespaceSuite (go.mondoo.com/mondoo-operator/tests/integration)
integration-tests-gke-1.27.xml [took 11m 9s]
integration-tests-gke-1.28.xml [took 8m 57s]
integration-tests-gke-1.29.xml [took 9m 40s]
Raw output
Failed
=== RUN TestAuditConfigCustomNamespaceSuite
Using GraphQL endpoint https://api.mondoo.com/query
Using org MRN //captain.api.mondoo.app/organizations/mondoo-operator-testing
2024-04-28T23:15:12Z INFO Created Nexus space {"space": "//captain.api.mondoo.app/spaces/cool-hofstadter-554596"}
2024-04-28T23:15:13.115Z INFO installer/installer.go:91 Installing Mondoo operator with local manifest
2024-04-28T23:15:13.115Z INFO utils/manifest_utils.go:54 Reading file: /home/runner/work/mondoo-operator/mondoo-operator/mondoo-operator-manifests.yaml
2024-04-28T23:15:13.115Z INFO utils/exec_utils.go:45 Running kubectl [apply -f -]
namespace/mondoo-operator created
customresourcedefinition.apiextensions.k8s.io/mondooauditconfigs.k8s.mondoo.com created
customresourcedefinition.apiextensions.k8s.io/mondoooperatorconfigs.k8s.mondoo.com created
serviceaccount/mondoo-operator-controller-manager created
serviceaccount/mondoo-operator-k8s-resources-scanning created
serviceaccount/mondoo-operator-webhook created
role.rbac.authorization.k8s.io/mondoo-operator-leader-election-role created
clusterrole.rbac.authorization.k8s.io/mondoo-operator-k8s-resources-scanning created
clusterrole.rbac.authorization.k8s.io/mondoo-operator-manager-role created
rolebinding.rbac.authorization.k8s.io/mondoo-operator-leader-election-rolebinding created
clusterrolebinding.rbac.authorization.k8s.io/mondoo-operator-k8s-resources-scanning created
clusterrolebinding.rbac.authorization.k8s.io/mondoo-operator-manager-rolebinding created
configmap/mondoo-operator-manager-config created
service/mondoo-operator-controller-manager-metrics-service created
deployment.apps/mondoo-operator-controller-manager created
2024-04-28T23:15:20.174Z INFO installer/installer.go:204 Created Мondoo client secret "mondoo-token".
2024-04-28T23:15:28.534Z INFO installer/installer.go:130 Mondoo operator is ready.
2024-04-28T23:15:28.604Z INFO integration/audit_config_namespace_test.go:36 Created test namespace.
2024-04-28T23:15:28.772Z INFO installer/installer.go:204 Created Мondoo client secret "mondoo-token".
2024-04-28T23:15:28.772Z INFO integration/audit_config_namespace_test.go:39 Created client secret in namespace "some-namespace".
2024-04-28T23:15:28.855Z INFO integration/audit_config_namespace_test.go:46 Created webhook ServiceAccount "webhook-sa" in namespace "some-namespace".
2024-04-28T23:15:28.923Z INFO integration/audit_config_namespace_test.go:53 Created service account "mondoo-sa" in namespace "some-namespace".
2024-04-28T23:15:29.056Z INFO integration/audit_config_namespace_test.go:66 Created cluster role binding "mondoo-operator-k8s-resources-scanning2".
--- FAIL: TestAuditConfigCustomNamespaceSuite (580.99s)
Check warning on line 0 in go.mondoo.com/mondoo-operator/tests/integration
github-actions / Test Results
1 out of 8 runs failed: TestAuditConfigSuite/TestReconcile_AdmissionEnforcing (go.mondoo.com/mondoo-operator/tests/integration)
integration-tests-gke-1.27.xml [took 56s]
Raw output
Failed
=== RUN TestAuditConfigSuite/TestReconcile_AdmissionEnforcing
2024-04-28T23:29:26.534Z INFO utils/audit_config.go:71 Using image ghcr.io/mondoohq/mondoo-operator/cnspec:latest-rootless for mondoo-client
2024-04-28T23:29:27.050Z INFO integration/audit_config_base_suite.go:572 Create an audit config that enables only admission control.
2024-04-28T23:29:29.247Z INFO integration/audit_config_base_suite.go:580 Waiting for webhook Pod to become ready.
2024-04-28T23:29:49.958Z INFO integration/audit_config_base_suite.go:585 Webhook Pod is ready.
2024-04-28T23:29:49.958Z INFO integration/audit_config_base_suite.go:827 Waiting for scan API Pod to become ready.
2024-04-28T23:29:50.017Z INFO integration/audit_config_base_suite.go:831 Scan API Pod is ready.
2024-04-28T23:29:50.097Z INFO integration/audit_config_base_suite.go:848 Waiting for good condition of Scan API
2024-04-28T23:29:54.764Z INFO integration/audit_config_base_suite.go:1097 Update the webhook with the CA data.
2024-04-28T23:29:54.915Z INFO integration/audit_config_base_suite.go:1106 Restart the webhook pods such that it is certain the CA secret has been reloaded.
audit_config_base_suite.go:1108:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1108
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:606
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:560
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:64
Error: Received unexpected error:
pods "mondoo-client-webhook-manager-fb99685d4-vwfzv" not found
Test: TestAuditConfigSuite/TestReconcile_AdmissionEnforcing
Messages: Failed to delete webhook pod
2024-04-28T23:30:01.295Z INFO integration/audit_config_base_suite.go:1116 Webhook Pod is ready.
2024-04-28T23:30:01.417Z INFO integration/audit_config_base_suite.go:1134 Getting endpoints for webhook.
2024-04-28T23:30:01.492Z INFO integration/audit_config_base_suite.go:1140 endpoints Addresses: [{10.24.0.52 0xc00095cca0 &ObjectReference{Kind:Pod,Namespace:mondoo-operator,Name:mondoo-client-webhook-manager-6d4dd66d8d-8njp7,UID:fae804f5-d83d-44da-8f0c-27f014af42a7,APIVersion:,ResourceVersion:,FieldPath:,}}]
2024-04-28T23:30:01.493Z INFO integration/audit_config_base_suite.go:1141 endpoints NotReadyAddresses: []
2024-04-28T23:30:01.493Z INFO integration/audit_config_base_suite.go:1148 Wait for webhook to start working.
2024-04-28T23:30:01.612Z INFO integration/audit_config_base_suite.go:614 Waiting for Webhook to accept connections (max 120s).
2024-04-28T23:30:01.613Z INFO integration/audit_config_base_suite.go:1169 Created port-forward via kubectl for webhook with pid: 5106
2024-04-28T23:30:03.853Z INFO integration/audit_config_base_suite.go:1182 Webhook is available: 404 Not Found
2024-04-28T23:30:03.853Z DEBUG integration/audit_config_base_suite.go:1209 Trying to stop port-forward with pid: 5106
2024-04-28T23:30:03.855Z INFO integration/audit_config_base_suite.go:617 Webhook should be working by now.
2024-04-28T23:30:03.855Z INFO integration/audit_config_base_suite.go:970 Create a Deployment which should pass. (max. 5 retries)
2024-04-28T23:30:12.872Z INFO integration/audit_config_base_suite.go:992 Create a Deployment which should be denied in enforcing mode.
2024-04-28T23:30:15.937Z INFO utils/k8s_helper.go:351 Resource /, Kind= mondoo-operator/passing-deployment deleted.
2024-04-28T23:30:16.010Z INFO utils/k8s_helper.go:351 Resource /, Kind= mondoo-operator/failing-deployment deleted.
2024-04-28T23:30:16.204Z INFO installer/installer.go:212 gathering all logs from the test
2024-04-28T23:30:16.204Z INFO utils/k8s_helper.go:256 Gathering logs for all pods in namespace mondoo-operator
2024-04-28T23:30:16.264Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/mondoo-operator_mondoo-client-scan-api-b6cf78c49-r699s_1714347016.log
2024-04-28T23:30:16.346Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/mondoo-operator_mondoo-client-webhook-manager-6d4dd66d8d-8njp7_1714347016.log
2024-04-28T23:30:16.427Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/mondoo-operator_mondoo-operator-controller-manager-6f89c5bfb4-kl6dw_1714347016.log
2024-04-28T23:30:16.513Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/mondoo-operator_mondoo-operator-controller-manager-6f89c5bfb4-kl6dw_previous_1714347016.log
2024-04-28T23:30:16.573Z DEBUG utils/executor.go:271 Running command: kubectl -n mondoo-operator logs mondoo-operator-controller-manager-6f89c5bfb4-kl6dw -c manager
2024-04-28T23:30:16.874Z INFO utils/k8s_helper.go:267 Gathering pod describe for all pods in namespace mondoo-operator
2024-04-28T23:30:16.934Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/describe_mondoo-operator_1714347016.log
2024-04-28T23:30:16.934Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-client-scan-api-b6cf78c49-r699s
2024-04-28T23:30:17.169Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-client-webhook-manager-6d4dd66d8d-8njp7
2024-04-28T23:30:17.402Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-operator-controller-manager-6f89c5bfb4-kl6dw
2024-04-28T23:30:17.675Z DEBUG utils/executor.go:271 Running command: kubectl get deployment -o yaml -n mondoo-operator mondoo-client-scan-api
2024-04-28T23:30:17.927Z DEBUG utils/executor.go:271 Running command: kubectl get deployment -o yaml -n mondoo-operator mondoo-client-webhook-manager
2024-04-28T23:30:18.178Z DEBUG utils/executor.go:271 Running command: kubectl get deployment -o yaml -n mondoo-operator mondoo-operator-controller-manager
2024-04-28T23:30:18.565Z DEBUG utils/executor.go:271 Running command: kubectl get mondooauditconfig -o yaml -n mondoo-operator mondoo-client
2024-04-28T23:30:18.799Z INFO utils/k8s_helper.go:318 Gathering events in namespace "mondoo-operator"
2024-04-28T23:30:18.799Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_AdmissionEnforcing/events_mondoo-operator_1714347018.log
2024-04-28T23:30:18.799Z DEBUG utils/executor.go:271 Running command: kubectl get events -n mondoo-operator
2024-04-28T23:30:19.374Z INFO utils/k8s_helper.go:347 Resource k8s.mondoo.com/v1alpha2, Kind=MondooAuditConfig mondoo-operator/mondoo-client still exists.
2024-04-28T23:30:21.441Z INFO utils/k8s_helper.go:351 Resource k8s.mondoo.com/v1alpha2, Kind=MondooAuditConfig mondoo-operator/mondoo-client deleted.
2024-04-28T23:30:21.441Z INFO installer/installer.go:192 Deleted MondooAuditConfig mondoo-operator/mondoo-client.
2024-04-28T23:30:21.799Z INFO integration/audit_config_base_suite.go:117 Waiting for cleanup of the test cluster.
2024-04-28T23:30:22.349Z INFO integration/audit_config_base_suite.go:142 Cleanup done. Cluster should be good to go for the next test.
2024-04-28T23:30:22.677Z DEBUG utils/executor.go:271 Running command: kubectl delete pods -n default --all --wait
--- FAIL: TestAuditConfigSuite/TestReconcile_AdmissionEnforcing (56.37s)
Check warning on line 0 in go.mondoo.com/mondoo-operator/tests/integration
github-actions / Test Results
3 out of 8 runs failed: TestAuditConfigSuite/TestReconcile_Containers (go.mondoo.com/mondoo-operator/tests/integration)
integration-tests-gke-1.27.xml [took 1m 47s]
integration-tests-gke-1.28.xml [took 2m 25s]
integration-tests-gke-1.29.xml [took 2m 28s]
Raw output
Failed
=== RUN TestAuditConfigSuite/TestReconcile_Containers
2024-04-28T23:32:46.723Z INFO utils/audit_config.go:71 Using image ghcr.io/mondoohq/mondoo-operator/cnspec:latest-rootless for mondoo-client
2024-04-28T23:32:46.723Z DEBUG utils/executor.go:271 Running command: kubectl run -n default nginx --image nginx -l app.kubernetes.io/name=nginx
2024-04-28T23:32:46.961Z DEBUG utils/executor.go:271 Running command: kubectl run -n default redis --image redis -l app.kubernetes.io/name=redis
2024-04-28T23:32:49.474Z INFO integration/audit_config_base_suite.go:252 Create an audit config that enables only workloads scanning.
2024-04-28T23:32:49.631Z INFO integration/audit_config_base_suite.go:262 Make sure the Mondoo k8s container image scan CronJob is created.
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:41
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/config-reloader@5a852aebfbd9 should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:41
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/gke-distroless/bash@17d23aa1d2cc should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:41
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/rule-evaluator@1f43e65c4c12 should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:41
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/operator@007b1eb9afba should be the default k8s policies
audit_config_base_suite.go:1269:
Error Trace: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:1269
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_base_suite.go:313
/home/runner/work/mondoo-operator/mondoo-operator/tests/integration/audit_config_test.go:41
Error: elements differ
extra elements in list A:
([]interface {}) (len=1) {
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security"
}
listA:
([]string) (len=3) {
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol",
(string) (len=59) "//policy.api.mondoo.app/policies/mondoo-kubernetes-security",
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security"
}
listB:
([]string) (len=2) {
(string) (len=54) "//policy.api.mondoo.app/policies/mondoo-linux-security",
(string) (len=45) "//policy.api.mondoo.app/policies/platform-eol"
}
Test: TestAuditConfigSuite/TestReconcile_Containers
Messages: Scored policies for asset gke.gcr.io/prometheus-engine/prometheus@4e54e60a9de0 should be the default k8s policies
2024-04-28T23:35:09.883Z INFO installer/installer.go:212 gathering all logs from the test
2024-04-28T23:35:09.883Z INFO utils/k8s_helper.go:256 Gathering logs for all pods in namespace mondoo-operator
2024-04-28T23:35:09.967Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_Containers/mondoo-operator_mondoo-client-containers-scan-28572454-cxdbb_1714347309.log
2024-04-28T23:35:10.146Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_Containers/mondoo-operator_mondoo-operator-controller-manager-8646559c78-sbtm2_1714347310.log
2024-04-28T23:35:10.277Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_Containers/mondoo-operator_mondoo-operator-controller-manager-8646559c78-sbtm2_previous_1714347310.log
2024-04-28T23:35:10.345Z DEBUG utils/executor.go:271 Running command: kubectl -n mondoo-operator logs mondoo-operator-controller-manager-8646559c78-sbtm2 -c manager
2024-04-28T23:35:10.747Z INFO utils/k8s_helper.go:267 Gathering pod describe for all pods in namespace mondoo-operator
2024-04-28T23:35:10.814Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_Containers/describe_mondoo-operator_1714347310.log
2024-04-28T23:35:10.814Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-client-containers-scan-28572454-cxdbb
2024-04-28T23:35:11.060Z DEBUG utils/executor.go:271 Running command: kubectl get pod -o yaml -n mondoo-operator mondoo-operator-controller-manager-8646559c78-sbtm2
2024-04-28T23:35:11.351Z DEBUG utils/executor.go:271 Running command: kubectl get deployment -o yaml -n mondoo-operator mondoo-operator-controller-manager
2024-04-28T23:35:11.667Z DEBUG utils/executor.go:271 Running command: kubectl get cronjob -o yaml -n mondoo-operator mondoo-client-containers-scan
2024-04-28T23:35:11.987Z DEBUG utils/executor.go:271 Running command: kubectl get mondooauditconfig -o yaml -n mondoo-operator mondoo-client
2024-04-28T23:35:12.218Z INFO utils/k8s_helper.go:318 Gathering events in namespace "mondoo-operator"
2024-04-28T23:35:12.218Z DEBUG utils/k8s_helper.go:545 created log file: /home/runner/work/mondoo-operator/mondoo-operator/tests/integration/_output/tests/AuditConfigSuite/TestReconcile_Containers/events_mondoo-operator_1714347312.log
2024-04-28T23:35:12.218Z DEBUG utils/executor.go:271 Running command: kubectl get events -n mondoo-operator
2024-04-28T23:35:12.848Z INFO utils/k8s_helper.go:351 Resource k8s.mondoo.com/v1alpha2, Kind=MondooAuditConfig mondoo-operator/mondoo-client deleted.
2024-04-28T23:35:12.848Z INFO installer/installer.go:192 Deleted MondooAuditConfig mondoo-operator/mondoo-client.
2024-04-28T23:35:12.998Z INFO integration/audit_config_base_suite.go:117 Waiting for cleanup of the test cluster.
2024-04-28T23:35:13.323Z INFO integration/audit_config_base_suite.go:142 Cleanup done. Cluster should be good to go for the next test.
2024-04-28T23:35:13.669Z DEBUG utils/executor.go:271 Running command: kubectl delete pods -n default --all --wait
--- FAIL: TestAuditConfigSuite/TestReconcile_Containers (148.52s)
Check warning on line 0 in go.mondoo.com/mondoo-operator/tests/integration
github-actions / Test Results
3 out of 8 runs failed: TestAuditConfigSuite (go.mondoo.com/mondoo-operator/tests/integration)
integration-tests-gke-1.27.xml [took 10m 19s]
integration-tests-gke-1.28.xml [took 10m 33s]
integration-tests-gke-1.29.xml [took 11m 43s]
Raw output
Failed
=== RUN TestAuditConfigSuite
Using GraphQL endpoint https://api.mondoo.com/query
Using org MRN //captain.api.mondoo.app/organizations/mondoo-operator-testing
2024-04-28T23:29:06Z INFO Created Nexus space {"space": "//captain.api.mondoo.app/spaces/sleepy-pascal-143195"}
2024-04-28T23:29:07.173Z INFO installer/installer.go:91 Installing Mondoo operator with local manifest
2024-04-28T23:29:07.173Z INFO utils/manifest_utils.go:54 Reading file: /home/runner/work/mondoo-operator/mondoo-operator/mondoo-operator-manifests.yaml
2024-04-28T23:29:07.173Z INFO utils/exec_utils.go:45 Running kubectl [apply -f -]
namespace/mondoo-operator created
customresourcedefinition.apiextensions.k8s.io/mondooauditconfigs.k8s.mondoo.com created
customresourcedefinition.apiextensions.k8s.io/mondoooperatorconfigs.k8s.mondoo.com created
serviceaccount/mondoo-operator-controller-manager created
serviceaccount/mondoo-operator-k8s-resources-scanning created
serviceaccount/mondoo-operator-webhook created
role.rbac.authorization.k8s.io/mondoo-operator-leader-election-role created
clusterrole.rbac.authorization.k8s.io/mondoo-operator-k8s-resources-scanning created
clusterrole.rbac.authorization.k8s.io/mondoo-operator-manager-role created
rolebinding.rbac.authorization.k8s.io/mondoo-operator-leader-election-rolebinding created
clusterrolebinding.rbac.authorization.k8s.io/mondoo-operator-k8s-resources-scanning created
clusterrolebinding.rbac.authorization.k8s.io/mondoo-operator-manager-rolebinding created
configmap/mondoo-operator-manager-config created
service/mondoo-operator-controller-manager-metrics-service created
deployment.apps/mondoo-operator-controller-manager created
2024-04-28T23:29:11.256Z INFO installer/installer.go:204 Created Мondoo client secret "mondoo-token".
2024-04-28T23:29:21.691Z INFO installer/installer.go:130 Mondoo operator is ready.
--- FAIL: TestAuditConfigSuite (703.20s)
Check notice on line 0 in .github
github-actions / Test Results
23 tests found
There are 23 tests, see "Raw output" for the full list of tests.
Raw output
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_Admission
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_AdmissionMissingSA
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_Containers
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_KubernetesResources
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_Nodes_CronJobs
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigCustomNamespaceSuite/TestReconcile_Nodes_Deployments
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigOOMSuite
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigOOMSuite/TestOOMControllerReporting
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigOOMSuite/TestOOMNodeScan_CronJob
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigOOMSuite/TestOOMNodeScan_Deployment
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigOOMSuite/TestOOMScanAPI
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_AdmissionEnforcing
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_AdmissionEnforcingScaleDownScanApi
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_AdmissionPermissive
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_AllDisabled
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_Containers
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_KubernetesResources
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_Nodes_CronJobs
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigSuite/TestReconcile_Nodes_Deployments
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigUpgradeSuite
go.mondoo.com/mondoo-operator/tests/integration ‑ TestAuditConfigUpgradeSuite/TestUpgradePreviousReleaseToLatest