Skip to content

cleanup(engine)!: only consider .yaml/.yml rule files#3551

Merged
poiana merged 3 commits intofalcosecurity:masterfrom
LucaGuerra:cleanup/only-consider-yaml-rule-files
May 12, 2025
Merged

cleanup(engine)!: only consider .yaml/.yml rule files#3551
poiana merged 3 commits intofalcosecurity:masterfrom
LucaGuerra:cleanup/only-consider-yaml-rule-files

Conversation

@LucaGuerra
Copy link
Copy Markdown
Contributor

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind cleanup

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area engine

What this PR does / why we need it:

Normally, Falco would try to load any file or directory specified in rules_files or with the -r option. However, if you are trying to load a non-yaml file or a directory which contains both yaml and other types of files Falco would emit a fatal error on the first file that fails to load. Since it makes sense to put also other files in the rule directory (such as a README) this PR restricts the files that are considered to .yaml and .yml, ignoring the rest. Likewise, single files that do not end in .yml or .yaml will not be loaded.

Thanks to @tks98 for noticing the behavior and suggesting this improvement!

/milestone 0.41.0

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

cleanup(engine)!: only consider .yaml/.yml rule files

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 9, 2025

This PR may bring feature or behavior changes in the Falco engine and may require the engine version to be bumped.

Please double check userspace/engine/falco_engine_version.h file. See versioning for FALCO_ENGINE_VERSION.

/hold

@LucaGuerra
Copy link
Copy Markdown
Contributor Author

/unhold

false positive

Copy link
Copy Markdown
Contributor

@FedeDP FedeDP left a comment

Choose a reason for hiding this comment

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

/approve

@poiana
Copy link
Copy Markdown
Contributor

poiana commented May 12, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: FedeDP, LucaGuerra

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

The pull request process is described here

Details 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

@poiana
Copy link
Copy Markdown
Contributor

poiana commented May 12, 2025

LGTM label has been added.

DetailsGit tree hash: d6abc15c3e0d35df67e103e672b2eeb55ac91cb9

@github-project-automation github-project-automation Bot moved this from Todo to In progress in Falco Roadmap May 12, 2025
@poiana poiana merged commit ae28be0 into falcosecurity:master May 12, 2025
34 checks passed
@github-project-automation github-project-automation Bot moved this from In progress to Done in Falco Roadmap May 12, 2025
@LucaGuerra LucaGuerra deleted the cleanup/only-consider-yaml-rule-files branch May 12, 2025 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants