Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: enhance CORS support #48

Merged

Conversation

rmikalkenas
Copy link

@rmikalkenas rmikalkenas commented Jun 16, 2023

Reason for This PR

roadrunner-server/roadrunner#909

  • adds possibility to define multiple allowed_origin values
  • leverages rs/cors library to handle CORS requests based on W3 specifications

Description of Changes

  • replaced CORS implementation to use rs/cors library
  • kept existing configuration backwards compatible (no breaking changes)

P.S. will update docs that allowed_origin now accepts multiple values separated by comma (if this PR gets approval)

License Acceptance

By submitting this pull request, I confirm that my contribution is made under
the terms of the MIT license.

PR Checklist

[Author TODO: Meet these criteria.]
[Reviewer TODO: Verify that these criteria are met. Request changes if not]

  • All commits in this PR are signed (git commit -s).
  • The reason for this PR is clearly provided (issue no. or explanation).
  • The description of changes is clear and encompassing.
  • Any required documentation changes (code and docs) are included in this PR.
  • Any user-facing changes are mentioned in CHANGELOG.md.
  • All added/changed functionality is tested.

@rmikalkenas rmikalkenas force-pushed the enhance-cors-support branch 2 times, most recently from a6ac9db to 65bc7c7 Compare June 16, 2023 13:36
@rustatian rustatian self-requested a review June 16, 2023 14:23
@rustatian rustatian added the enhancement New feature or request label Jun 16, 2023
@rustatian
Copy link
Member

Hey @rmikalkenas 👋🏻 Thanks for the PR 👍🏻

@rustatian rustatian changed the title Enhance CORS support feature: enhance CORS support Jun 16, 2023
plugin.go Outdated Show resolved Hide resolved
plugin.go Outdated Show resolved Hide resolved
@rustatian
Copy link
Member

If you have any additional questions - feel free to ping me here or in the our Discord server 👍🏻

@rustatian rustatian marked this pull request as draft June 16, 2023 15:07
@rmikalkenas rmikalkenas force-pushed the enhance-cors-support branch 2 times, most recently from a2e57a5 to 68794e8 Compare June 18, 2023 13:44
@rmikalkenas
Copy link
Author

If you have any additional questions - feel free to ping me here or in the our Discord server 👍🏻

@rustatian thanks for the comments 👍 updated the PR. Let me know what you think

@rmikalkenas rmikalkenas marked this pull request as ready for review June 18, 2023 13:49
plugin.go Outdated Show resolved Hide resolved
Signed-off-by: Rokas Mikalkėnas <[email protected]>
Copy link
Member

@rustatian rustatian left a comment

Choose a reason for hiding this comment

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

LGTM, thank you @rmikalkenas 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants