#CORS with Object Storage/Bucket

2 messages · Page 1 of 1 (latest)

snow comet
#

Hey all,

I know that Railway object storage is new and in Beta, but I stayed away from Minio given their recent changes and dove in with Railway.

I am somewhat new to object storage. I was able to set up a different project hosted in Railway using AWS S3 without issue, But I am working on a new project and can't seem to get Object Storage to work due to CORS errors.

I have all of the variables defined in my local dev and railway environment,

Is there any documentation to review best practices?

Thanks in advance!

blissful vaultBOT
#

New reply sent from Central Station thread:

Hey Mate !
One thing to note is that
buckets are private by default
.
That means browsers can’t access them directly, which is likely why you’re getting CORS errors.
To fix this, you’ll need to deploy a small
public proxy
(for example, a simple Node.js or Python service) that serves files from your bucket and includes proper CORS headers like:
Access-Control-Allow-Origin: *
This proxy acts as a “public front door” to your private bucket.
Until Railway adds built-in CORS or public file access, I think that’s the recommended workaround.
I hope this helps

You're seeing this because this thread has been automatically linked to the Central Station thread.