#440 Gate on package test results.
Merged 4 years ago by gnaponie. Opened 4 years ago by adelton.
adelton/greenwave gate-on-package-tests  into  master

@@ -25,7 +25,14 @@ 

     decision_context: bodhi_update_push_testing

     subject_type: koji_build

     rules:

-      - !PassingTestCaseRule {test_case_name: dist.depcheck}

+      - !PassingTestCaseRule {test_case_name: org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete}

+    --- !Policy

+    product_versions:

+      - fedora-*

+    decision_context: bodhi_update_push_stable

+    subject_type: koji_build

+    rules:

+      - !PassingTestCaseRule {test_case_name: org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete}

  

  The structure of the file is the same as the policies in Greenwave's

  configuration, with the only difference that the "id" key is optional.

In https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/5QVYP53EO5O43UCRQSTNUP2M3YSE24MM/ Adam suggests that dist.depcheck hasn't been used for a while

I've checked that org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete will cause gating to stop errata when tests for the package fail in Fedora CI.

Hello @adelton, did you intend to change the policies? This is just Greenwave documentation, and the testcase there is just an example.
Greenwave policies are stored in fedora in another repo, here:
https://infrastructure.fedoraproject.org/cgit/ansible.git/tree/roles/openshift-apps/greenwave/templates

You'll then need access to batcave01 and run the playbook: openshift-apps/greenwave.yml to apply your changes.
This repo only has the code base of the service, it is not connected to any specific configuration.

PS. when you change the policies, please make sure to follow the documentation. The "subject_type" field is needed.

I intended to provide some documentation for people who struggle finding information about enabling gating for their package tests. The existing dist.depcheck does not do the trick, org.centos.prod.ci.pipeline.allpackages-build.package.test.functional.complete seems to enable gating on the package test results.

I don't have any idea what policies are. I just try to provide reasonable example of gating.yaml.

As for subject_type, it does not seem to be needed in per-package gating.yaml file.

I see. That's fine by me. It doesn't really matter which example is in the doc, as long as the syntax is correct.

Yeah, subject_type is not mandatory, but it is needed. If not provided the default will be "koji_build". That is always the case in Fedora at the moment, but it is not always the same internally. And it might change in the future.
So I would leave it. I don't see problems in leaving it as it is.

rebased onto f286008

4 years ago

Updated the pull request to keep the subject_type -> f286008.

I'm trying to merge this PR but the task keeps remain "pending"...

Pull-Request has been merged by gnaponie

4 years ago
Metadata