chore: ignore server-generated PHP config files - #1764
Open
Satendra-SR wants to merge 1 commit into
Open
Conversation
PHP-FPM reads a per-directory `.user.ini`, and Wordfence writes `wordfence-waf.php` into the web root when Extended Protection is on. Both are generated on the server, differ per environment, and are not meant to be version-controlled — the same category as `/.htaccess` and `wp-config.php`, which are already ignored here. Neither file is tracked today, so nothing about what gets deployed changes. This stops them appearing as untracked in `git status` on every server, and removes the chance of one being committed by accident. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds two entries to
.gitignore:Why
Both files are generated on the server, not authored in the repo:
.user.ini— PHP-FPM (and CGI) reads a per-directory.user.inifor PHP settings. It is the FPM equivalent of thephp_valuedirectives that.htaccesscarries under mod_php, and its contents are environment-specific.wordfence-waf.php— Wordfence writes this into the web root when Extended Protection is enabled, and pointsauto_prepend_fileat it.This is the same category as
/.htaccessandwp-config.php, which this file already ignores for exactly the same reason.Impact
Neither file is tracked today, so nothing about what gets deployed changes. Two things improve:
git statuson every server that has them.Low risk — additive only, no tracked file is affected.
🤖 Generated with Claude Code