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

chore(ci): fix sanity checks & re-enable audit-log for showcase #2417

Merged

Conversation

zdrapela
Copy link
Member

@zdrapela zdrapela commented Feb 19, 2025

Description

This changes how sanity check plugins are loaded into NAME_SPACE_SANITY_PLUGINS_CHECK deployment. By merging the file with the base one, we should avoid conflicts with duplicate configurations of the plugins.
It uses the logic from here:

# Merge the base YAML value file with the differences file for Kubernetes
yq_merge_value_files() {
local base_file=$1
local diff_file=$2
local step_1_file="/tmp/step-without-plugins.yaml"
local step_2_file="/tmp/step-only-plugins.yaml"
local final_file=$3
# Step 1: Merge files, excluding the .global.dynamic.plugins key
# Values from `diff_file` override those in `base_file`
yq eval-all '
select(fileIndex == 0) * select(fileIndex == 1) |
del(.global.dynamic.plugins)
' "${base_file}" "${diff_file}" > "${step_1_file}"
# Step 2: Merge files, combining the .global.dynamic.plugins key
# Values from `diff_file` take precedence; plugins are merged and deduplicated by the .package field
yq eval-all '
select(fileIndex == 0) *+ select(fileIndex == 1) |
.global.dynamic.plugins |= (reverse | unique_by(.package) | reverse)
' "${base_file}" "${diff_file}" > "${step_2_file}"
# Step 3: Combine results from the previous steps and remove null values
# Values from `step_2_file` override those in `step_1_file`
yq eval-all '
select(fileIndex == 0) * select(fileIndex == 1) | del(.. | select(. == null))
' "${step_2_file}" "${step_1_file}" > "${final_file}"
}

Which issue(s) does this PR fix

PR acceptance criteria

Please make sure that the following steps are complete:

  • GitHub Actions are completed and successful
  • Unit Tests are updated and passing
  • E2E Tests are updated and passing
  • Documentation is updated if necessary (requirement for new features)
  • Add a screenshot if the change is UX/UI related

How to test changes / Special notes to the reviewer

@zdrapela
Copy link
Member Author

/test

Copy link

openshift-ci bot commented Feb 19, 2025

@zdrapela: The /test command needs one or more targets.
The following commands are available to trigger required jobs:

/test e2e-tests

The following commands are available to trigger optional jobs:

/test cleanup-mapt-destroy-orphaned-aks-clusters
/test e2e-tests-aks-helm-nightly
/test e2e-tests-gke-helm-nightly
/test e2e-tests-nightly
/test e2e-tests-operator-nightly
/test e2e-tests-osd-gcp-helm-nightly
/test e2e-tests-osd-gcp-operator-nightly

Use /test all to run the following jobs that were automatically triggered:

pull-ci-redhat-developer-rhdh-main-e2e-tests

In response to this:

/test

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.

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

1 similar comment
@zdrapela
Copy link
Member Author

/test e2e-tests-nightly

@zdrapela
Copy link
Member Author

/test e2e-tests

1 similar comment
@zdrapela
Copy link
Member Author

/test e2e-tests

@gustavolira
Copy link
Contributor

/lgtm

Copy link

openshift-ci bot commented Feb 20, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gustavolira

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 5181471 into redhat-developer:main Feb 20, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants