Repository navigation
Conversation
admirerr
left a comment
There was a problem hiding this comment.
Hi @CJstate , thanks for this contribution, the change itself looks good.
One repo policy item before I can merge: the commits on this PR carry a Co-Authored-By: Claude Code trailer. Aegora does not credit AI tools as co-authors on any PR, so I cannot merge commits that name an AI as a co-author. This is a blanket rule for the repo and nothing about the quality of this change. Human co-authors are welcome anytime.
Could you remove the Co-Authored-By: Claude Code line from the commit message(s) on this branch and push the updated commits? Everything else can stay exactly as it is. Once that is done I will merge right away.
Thanks again for contributing.
|
Removed the |
|
Hi @admirerr — following up on the review. The current head is |
Add a top-level cors block with allowed origins, methods, headers and max_age. The middleware answers preflight OPTIONS with 204 before shedding, rate limiting or queue admission, sets Vary: Origin for restricted origins, and leaves disallowed origins untouched. Tests cover validation, YAML loading, the middleware matrix and a buildApp integration preflight. Fixes syncronix-labs#31.
|
Done — I removed the |
|
Update: the commit messages on this branch no longer contain any |
|
Thanks for the review. I've checked the current commits on this branch: none of them carry a |
|
Hi, following up on this PR. The current head no longer carries any Co-Authored-By or AI attribution trailer, and CI is green. If there is anything else blocking the merge, please let me know; otherwise could you re-submit the review? Thanks. |
|
Thanks for the review. The commit on this PR has been rewritten and no longer carries any |
What
Adds a top-level
corsblock and a middleware that:Access-Control-Allow-Originfor configured origins, withVary: Originon restricted responsesOPTIONSwith204before shedding, rate limiting or queue admissionAccess-Control-Max-AgeDisabled by default: with
cors.enabled: false(or no block), behavior is unchanged.Why
Browser clients have no way to call APIs through the gateway cross-origin today. The gateway already terminates the browser-facing edge, so it is the right place for this rather than each backend.
Verification
go test ./internal/config/... ./internal/middleware/... ./cmd/aegora/...golangci-lint run ./...→ 0 issuesbuildApptest proves the preflight is handled by the assembled chainFixes #31.