Thanks to visit codestin.com
Credit goes to github.com

Skip to content

feat: bypass built-in CORS handling for workspace apps #17596

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

Open
wants to merge 19 commits into
base: main
Choose a base branch
from

Conversation

Emyrk
Copy link
Member

@Emyrk Emyrk commented Apr 28, 2025

Continues #15669

This PR introduces a partial fix for #15096; it allows operators to specify the CORS behavior on a per-coder_app level.

This change requires cors_behavior to be set on a given coder_app; coder/terraform-provider-coder#309 introduces that new attribute.

coderd currently handles CORS automatically by handling preflight requests and stripping CORS headers from upstream coder_app responses.

Two CORS behaviors are defined in this PR:

  • simple: the current behavior of handling CORS within coderd
  • passthru: new behavior which transparently bypasses our CORS handling in coderd so the coder_app service is then fully responsible for handling CORS

We plan to further add this behavior to port shares.

The sharing level (owner, authenticated, public) is still respected, regardless of CORS behavior.

@Emyrk Emyrk changed the title Stevenmasley/cors feat: bypass built-in CORS handling for workspace apps Apr 28, 2025
Copy link


🚀 Deploying PR 17596 ...

@github-actions github-actions bot added the stale This issue is like stale bread. label May 7, 2025
@f0ssel f0ssel requested review from cstyan and removed request for cstyan May 8, 2025 14:38
@github-actions github-actions bot removed the stale This issue is like stale bread. label May 9, 2025
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.

2 participants