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

feat(config): allow R2 bucket URLs #7097

Merged
merged 1 commit into from
Feb 21, 2024
Merged

feat(config): allow R2 bucket URLs #7097

merged 1 commit into from
Feb 21, 2024

Conversation

LoneRifle
Copy link
Contributor

@LoneRifle LoneRifle commented Feb 20, 2024

Problem

FormSG assumes in production environments that S3 buckets are hosted by AWS and use URLs that take after a certain pattern. This is not necessarily the case for eg, Cloudflare R2, which use a different pattern

Solution

  • Allow config to accept URLs to R2 buckets, in addition to S3 buckets
  • Force path-style S3 URLs for R2 buckets, not just for dev mode

@LoneRifle LoneRifle marked this pull request as draft February 20, 2024 10:25
@LoneRifle LoneRifle marked this pull request as ready for review February 20, 2024 12:02
src/app/config/config.ts Fixed Show fixed Hide fixed
@LoneRifle LoneRifle force-pushed the feat/config/r2 branch 3 times, most recently from c26571a to ef35d7a Compare February 20, 2024 12:13
src/app/config/config.ts Fixed Show fixed Hide fixed
src/app/config/schema.ts Outdated Show resolved Hide resolved
- Allow config to accept URLs to R2 buckets, in addition to S3 buckets
- Force path-style S3 URLs for R2 buckets, not just for dev mode
@LoneRifle LoneRifle merged commit 956620a into develop Feb 21, 2024
21 checks passed
@LoneRifle LoneRifle deleted the feat/config/r2 branch February 21, 2024 03:12
@justynoh justynoh mentioned this pull request Feb 21, 2024
30 tasks
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.

None yet

2 participants