Skip to content

docs: add web server configuration guide for feature branch deployment#22

Merged
konradmichalik merged 3 commits intomainfrom
docs/webserver-configuration
Feb 23, 2026
Merged

docs: add web server configuration guide for feature branch deployment#22
konradmichalik merged 3 commits intomainfrom
docs/webserver-configuration

Conversation

@konradmichalik
Copy link
Contributor

@konradmichalik konradmichalik commented Feb 23, 2026

Summary

  • Add dedicated docs/WEBSERVER.md covering Apache and nginx prerequisites for feature branch deployments
  • Document nginx server block examples for both TYPO3 and Symfony applications
  • Reference new web server guide from docs/FEATURE.md prerequisites section

Changes

  • docs/WEBSERVER.md - New guide covering Apache (AllowOverride All) and nginx (symlinks, PHP-FPM, URL rewriting with example configs)
  • docs/FEATURE.md - Add web server reference link in prerequirements, following the existing DATABASE.md pattern
  • deployer/requirements/functions.php - Apply yoda conditions and fn spacing (CGL)

Summary by CodeRabbit

  • Documentation
    • Expanded feature-deployment docs with new prerequisites, initialization, deletion, notification, synchronization, scheduler, cleanup, FAQ and guidance for serving feature branches.
    • Added comprehensive web-server deployment guide (Apache/nginx) with TYPO3/Symfony examples, PHP-FPM notes, symlink handling and sample configurations.
  • Style
    • Normalized comparison operand order and minor whitespace formatting across helper functions to unify code style.

@coderabbitai
Copy link

coderabbitai bot commented Feb 23, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4452987 and 425af2c.

📒 Files selected for processing (1)
  • docs/WEBSERVER.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/WEBSERVER.md

📝 Walkthrough

Walkthrough

The PR performs stylistic refactoring of comparison expressions in deployer/requirements/functions.php, adds detailed webserver configuration documentation (docs/WEBSERVER.md), and expands feature-deployment guidance in docs/FEATURE.md (prerequisites, sections, and examples). Changes do not alter exported APIs.

Changes

Cohort / File(s) Summary
Comparison Operand Refactoring
deployer/requirements/functions.php
Normalized ordering of equality/identity and null/empty comparisons across multiple helper functions (operand order reversed, whitespace normalized). Logic and behavior retained.
Feature Deployment Documentation
docs/FEATURE.md
Added prerequisite guidance for webserver configuration, YAML snippet for feature-branch-deployment labeling, and new top-level sections (Initialization, Deletion, Notification, Synchronization, Info, Pathing, Scheduler, Cleanup, FAQ).
Webserver Documentation
docs/WEBSERVER.md
New documentation covering Apache and nginx setup, per-server-block rewrite considerations, TYPO3 and Symfony example configs, symlink handling, PHP-FPM notes, and a deployer config example.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Poem

🐰 Hopping through lines with a tidy cheer,

I flip some comparisons — nothing to fear.
Docs bloom for nginx and Apache delight,
Feature branches ready, shining bright.
A small rabbit nods, then bounds out of sight.

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 75.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the primary change: adding web server configuration documentation for feature branch deployment, which is the main focus of the PR.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs/webserver-configuration

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
docs/WEBSERVER.md (1)

44-48: deny all; is unreachable — return 403; alone is sufficient.

In nginx's processing pipeline, return (rewrite phase) runs before deny (access phase). Once return 403; is evaluated, the access module never runs, making deny all; dead configuration. Using either directive alone is cleaner.

♻️ Proposed simplification
     # Deny access to protected directories across all instances
     location ~ /(typo3conf|var|config)/ {
-        deny all;
         return 403;
     }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/WEBSERVER.md` around lines 44 - 48, The nginx location block "location ~
/(typo3conf|var|config)/" contains both "deny all;" and "return 403;", but
"return 403;" executes earlier and makes "deny all;" unreachable; remove the
redundant "deny all;" (or alternatively remove "return 403;") so only a single
directive enforces the 403 response in that location block, keeping the location
regex and message unchanged.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/WEBSERVER.md`:
- Around line 51-56: Add a short adaptation note and inline comment around the
PHP location block (the location ~ \.php$ { ... } section) explaining that the
fastcgi_pass path (fastcgi_pass unix:/run/php/php-fpm.sock;) is
Debian/Ubuntu-specific and list common alternatives (e.g.,
/run/php/php8.x-fpm.sock for versioned Ubuntu, /run/php-fpm/www.sock for
CentOS/RHEL, or TCP 127.0.0.1:9000 for custom setups); update both the TYPO3 and
Symfony examples and include the comment next to the fastcgi_pass line so users
know to adjust the socket to avoid 502 errors.

---

Nitpick comments:
In `@docs/WEBSERVER.md`:
- Around line 44-48: The nginx location block "location ~
/(typo3conf|var|config)/" contains both "deny all;" and "return 403;", but
"return 403;" executes earlier and makes "deny all;" unreachable; remove the
redundant "deny all;" (or alternatively remove "return 403;") so only a single
directive enforces the 403 response in that location block, keeping the location
regex and message unchanged.

ℹ️ Review info

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ca66943 and 4452987.

📒 Files selected for processing (3)
  • deployer/requirements/functions.php
  • docs/FEATURE.md
  • docs/WEBSERVER.md

@konradmichalik
Copy link
Contributor Author

@coderabbitai Good catch on the unreachable deny all; — removed the redundant directive, keeping only return 403;. 425af2c

@coderabbitai
Copy link

coderabbitai bot commented Feb 23, 2026

Tip

For best results, initiate chat on the files or code changes.

@konradmichalik, thank you for addressing that! The configuration is now cleaner and more maintainable with just the return 403; directive. 🎉

(\___/)
(='.'=)
(")_(")
Happy rabbit!

@konradmichalik konradmichalik merged commit ea4bac3 into main Feb 23, 2026
2 checks passed
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.

1 participant