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

CI improvements #927

Merged
merged 6 commits into from
Jan 8, 2025
Merged

CI improvements #927

merged 6 commits into from
Jan 8, 2025

Conversation

petrutlucian94
Copy link
Contributor

@petrutlucian94 petrutlucian94 commented Dec 31, 2024

  • inspect.sh "--detailed" flag that collects logs from all namespaces
  • moved copied TICS and Trivy tests to separate scripts
    • these workflows run against other branches (main, release/*). We need to backport the scripts there before being able to clean up the workflows.

The "inspect.sh" script currently retrieves logs from the
kube-system and default namespaces, which sometimes isn't enough
to identify cluster problems.

We're adding a "--detailed" setting that will collect logs from
all namespaces. This won't be the default since the logs may
contain sensitive user information.
@petrutlucian94 petrutlucian94 requested a review from a team as a code owner December 31, 2024 08:57
We're moving the Trivy and Tics test logic to separate scripts,
simplifying the GH workflows and allowing these tests to be invoked
locally.
@petrutlucian94 petrutlucian94 force-pushed the lpetrut/ci-improvements branch from 7eeaa34 to efce8a8 Compare December 31, 2024 09:21
We moved those tests to separate scripts, however the workflows
also run against other branches (main and release/*).

We'll be able to clean up the workflows only after backporting those
changes to the other branches.
@petrutlucian94 petrutlucian94 force-pushed the lpetrut/ci-improvements branch from efce8a8 to 01eecbd Compare December 31, 2024 09:34
@eaudetcobello
Copy link
Contributor

Thanks @petrutlucian94! Adding a flag is OK with me, but is it possible to always collect info. from all namespaces? Does this pollute the inspection report too much for the majority of cases?

tests/tics-scan.sh Outdated Show resolved Hide resolved
tests/tics-scan.sh Outdated Show resolved Hide resolved
tests/tics-scan.sh Outdated Show resolved Hide resolved
Copy link
Contributor

@bschimke95 bschimke95 left a comment

Choose a reason for hiding this comment

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

Generally LGTM, +1 on @eaudetcobello comments

@@ -173,6 +180,25 @@ if [ "$EUID" -ne 0 ]; then
exit 1
fi

POSITIONAL_ARGS=()
while [[ $# -gt 0 ]]; do
Copy link
Contributor

Choose a reason for hiding this comment

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

Bash is such a beautiful and simple language.

k8s/scripts/inspect.sh Outdated Show resolved Hide resolved
@petrutlucian94
Copy link
Contributor Author

Thanks @petrutlucian94! Adding a flag is OK with me, but is it possible to always collect info. from all namespaces? Does this pollute the inspection report too much for the majority of cases?

There were concerns about collecting sensitive user data: #892 (comment)

@bschimke95 bschimke95 merged commit 025ff67 into main Jan 8, 2025
19 checks passed
@bschimke95 bschimke95 deleted the lpetrut/ci-improvements branch January 8, 2025 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants