Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Github Action Ansible shell module changes check #12014

Merged
merged 1 commit into from
May 29, 2024

Conversation

mildas
Copy link
Contributor

@mildas mildas commented May 21, 2024

Description:

CI check to notify if a Ansible shell/command module usage has been changed.
It's preferred to use specific Ansible module rather than abuse shell (command) module. So we want to have shell (command) module used only in approved corner cases when there is no other option.

Review Hints:

See Compare DS / Generate Diff (pull_request) check and bot PR comments.
There is extra commit to trigger the updated CI. The commit must be removed before merging.

It's seems as it's not possible to show it in CaC/content repo CI before merge. To show the check, I've created extra PR in my private repo - mildas#3 (see Compare DS / Generate Diff (pull_request) check and bot PR comments)

@mildas mildas added enhancement General enhancements to the project. Test Suite Update in Test Suite. labels May 21, 2024
Copy link

github-actions bot commented May 21, 2024

Start a new ephemeral environment with changes proposed in this pull request:

Fedora Environment
Open in Gitpod

Oracle Linux 8 Environment
Open in Gitpod

Copy link

github-actions bot commented May 21, 2024

🤖 A k8s content image for this PR is available at:
ghcr.io/complianceascode/k8scontent:12014
This image was built from commit: 78f77a5

Click here to see how to deploy it

If you alread have Compliance Operator deployed:
utils/build_ds_container.py -i ghcr.io/complianceascode/k8scontent:12014

Otherwise deploy the content and operator together by checking out ComplianceAsCode/compliance-operator and:
CONTENT_IMAGE=ghcr.io/complianceascode/k8scontent:12014 make deploy-local

utils/ansible_shell_diff.py Show resolved Hide resolved
utils/ansible_shell_diff.py Outdated Show resolved Hide resolved
@mildas
Copy link
Contributor Author

mildas commented May 23, 2024

@matusmarhefka Updated (pushed the change also to my fork PR so it's shown in that GH CI check as well).

matusmarhefka
matusmarhefka previously approved these changes May 23, 2024
@matusmarhefka matusmarhefka self-assigned this May 23, 2024
@matusmarhefka matusmarhefka dismissed their stale review May 23, 2024 15:17

codeclimate detected an issue in code

Copy link

codeclimate bot commented May 27, 2024

Code Climate has analyzed commit 78f77a5 and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 2

Note: there is 1 critical issue.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 59.4% (0.0% change).

View more on Code Climate.

@matusmarhefka matusmarhefka merged commit 731dde4 into ComplianceAsCode:master May 29, 2024
111 of 113 checks passed
@mildas mildas deleted the ansible_shell_diff branch July 17, 2024 12:46
@Mab879 Mab879 added this to the 0.1.75 milestone Aug 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement General enhancements to the project. Test Suite Update in Test Suite.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants