Skip to content

Conversation

@ggbecker
Copy link
Member

@ggbecker ggbecker commented Jun 8, 2021

Description:

  • Only enable ansible/yaml lint tests when playbooks are built
  • Add two tests to ansible playbooks per profile since there are a few post-processing made by python scripts and it makes sense to test them in addition to playbooks per rule.

Relates to #7039

@ggbecker ggbecker added the Ansible Ansible remediation update. label Jun 8, 2021
@ggbecker ggbecker added this to the 0.1.57 milestone Jun 8, 2021
@ggbecker ggbecker marked this pull request as draft June 8, 2021 17:13
@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Used by openshift-ci bot. label Jun 8, 2021
@ggbecker ggbecker force-pushed the fix-ansible-checks-test branch from 648ab08 to 51a3e1f Compare June 8, 2021 17:17
@ggbecker ggbecker marked this pull request as ready for review June 8, 2021 17:17
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Used by openshift-ci bot. label Jun 8, 2021
@JAORMX
Copy link
Contributor

JAORMX commented Jun 9, 2021

/retest

@ggbecker ggbecker force-pushed the fix-ansible-checks-test branch from 51a3e1f to 1fce2fd Compare June 9, 2021 10:41
@yuumasato yuumasato self-assigned this Jun 9, 2021
@ggbecker ggbecker force-pushed the fix-ansible-checks-test branch from 1fce2fd to 13054de Compare June 9, 2021 14:16
Note: Ansible playbooks per rule are not rendered by OpenSCAP thus the
OpenSCAP version test is not needed in this case.
@ggbecker ggbecker force-pushed the fix-ansible-checks-test branch from 13054de to 3435288 Compare June 9, 2021 15:27
@ggbecker ggbecker changed the title Enable playbooks per rule when ANSIBLE_CHECKS is on. Only enable ansible/yaml lint tests when playbooks are built Jun 9, 2021
@ggbecker
Copy link
Member Author

ggbecker commented Jun 9, 2021

The PR has turned into a different direction as we realized it makes more sense to tests things that are actually being built and not force to build content to be tested. So the ansible/yamllint tests are enabled only the flags to build the ansible content is enabled.

@JAORMX
Copy link
Contributor

JAORMX commented Jun 10, 2021

/retest

Copy link
Member

@yuumasato yuumasato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good, just found one issue with tests when profile playbooks are not built.

…ption.

The option SSG_ANSIBLE_PLAYBOOKS_ENABLED must be enabled in order to be
able to check the syntax of ansible playbooks per profile. Otherwise
these files won't be built and the test will always fail.
Copy link
Member

@yuumasato yuumasato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just pending jenkins.

@openshift-ci
Copy link

openshift-ci bot commented Jun 10, 2021

@ggbecker: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/e2e-aws-ocp4-moderate dd273ee link /test e2e-aws-ocp4-moderate

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/test-infra repository. I understand the commands that are listed here.

@yuumasato
Copy link
Member

yuumasato commented Jun 10, 2021

I see some rules report Status: FAIL, but I don't think these are related to this PR.
There are also some infra issues.
CC: @JAORMX

@yuumasato yuumasato merged commit 2f3d9a6 into ComplianceAsCode:master Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ansible Ansible remediation update.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants