Repository navigation
fix (shared-notes-server/cluster): Use $bbb_cors_origin for shared-notes-server Allow-Origin (CORS) - #25194
Conversation
WalkthroughThis PR refactors CORS origin handling in the nginx template for the shared notes server. It replaces direct use of Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In
`@build/packages-template/bbb-shared-notes-server/bbb-shared-notes-server.nginx`:
- Around line 1-4: The nginx config sets $bbb_cors_origin to '*' when empty
which conflicts with credentialed CORS because /hocuspocus/api/ returns
Access-Control-Allow-Origin: $bbb_cors_origin together with
Access-Control-Allow-Credentials: true; change the fallback behavior so that
when $bbb_cors_origin is empty you set it to the incoming request origin
($http_origin) or implement an origin allowlist/denylist check and only emit '*'
for responses that do not return Access-Control-Allow-Credentials, ensuring
Access-Control-Allow-Origin is never '*' when Access-Control-Allow-Credentials:
true for routes like /hocuspocus/api/.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: be1d3b83-2ccd-46ef-b595-c74cbfeda45c
📒 Files selected for processing (1)
build/packages-template/bbb-shared-notes-server/bbb-shared-notes-server.nginx
✅ Automated tests have passed! |



Now Docs will recommend to set
$bbb_cors_originfor cluster/proxy setups.So
bbb-shared-notes-servercan benefit from it instead of allowing$http_originalways.More info: #25108