-
-
Notifications
You must be signed in to change notification settings - Fork 117
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
Can't use S3 Sdk - SignatureDoesNotMatch #495
Comments
Hello, https://github.com/supabase/storage/blob/master/docker-compose.yml#L46-L47 Let me know if that work |
If you check the |
are you running storage behind a reverse proxy? If yes, you'd need to add the |
If you are not, don't set the S3_PREFIX_URL, and the URL you are using to connect to storage shouldn't contain the const s3Client = new S3Client({
logger: console,
forcePathStyle: true,
region: "stub",
endpoint: "http://localhost:5000/s3",
// endpoint: "http://localhost:9000",
credentials: {
accessKeyId: "supa-storage",
secretAccessKey: "secret1234",
},
}); |
I'm running the default Following your instructions I'd added the follwoing to my # ...
S3_PROTOCOL_PREFIX: /storage/v1 # Added
# ...
S3_PROTOCOL_ACCESS_KEY_ID: supa-storage
S3_PROTOCOL_ACCESS_KEY_SECRET: secret1234
AWS_ACCESS_KEY_ID: supa-storage
AWS_SECRET_ACCESS_KEY: secret1234 and then request with: const s3Client = new S3Client({
logger: console,
forcePathStyle: true,
region: "stub",
endpoint: "http://localhost:5000/storage/v1/s3",
credentials: {
accessKeyId: "supa-storage",
secretAccessKey: "secret1234",
},
});
const createBucketRequest = new CreateBucketCommand({
Bucket: "test-bucket",
ACL: "public-read",
}); But still got the same error. Storage container logs
|
Right! if you use kong you'll need to add this snippet in the storage route: |
Just be more specific, you'll need to update this line on the supabase repo you have linked: https://github.com/supabase/supabase/blob/master/docker/volumes/api/kong.yml#L64 The host will be the host you are accessing Kong, in development will be @kallebysantos let me know if this works for you, I'm quite confident it will since we use the same setup on the supabase cli |
So I need to update both: I'd follow the other steps that you provide but it didn't work, I'll try to redo everything again in a new fresh installation of supabase. Thank you, I'll let you know 🙏 I just don't have much time for now, a guy in my team decided to not move on with supabase in this project 😭😭 and I need to redo everything that I spend a whole month in another stack. But this |
It will work since we use the same setup on the supabase cli. I'll be closing this issue for now, however if you need need any more help on this, please feel free to comment below and I can re-open in case. |
Hey @fenos I'm self-hosting, and tried to follow the steps you wrote above. Am seeing the
Standard and Resumable uploads work. At one point I was getting the following error:
But that seems to have been my mistake with restarting the containers properly, because I'm not seeing this anymore. Now I get the Any pointers on what I could be doing wrong? Is there anything more I can share that could help? Storage configThese are the environment variables for the storage container:
Kong configMy kong config for the storage-v1 path is as follows: Notice the
Python Boto3Example of how I'm doing the upload from a client application with Python and boto3. Couldn't find anything about using Python in the docs, so lots of guessing and trying.
|
Bug report
Describe the bug
I'm trying to use
S3 Sdk
to perform operations on Supabase Storage. But everyCommand
that I try simple doesn't works and result in403: SignatureDoesNotMatch
error. But if I call to Minio endpoint instead it works.To Reproduce
Run
docker-compose.s3.yml
with the following:code
Then I copy the following code from supabase storage tests:
Current behaviour
Application Logs:
Supabase Storage Logs:
Expected behavior - Calling :9000 (Minio)
Application Logs:
Minio dashboard:
System information
Additional context
In the example provide I use the
CreateBucketCommand
but the same occours when I trying to upload Multipart documents, like the following snippet copied fromSupabase docs
:Uploading to Supabase Storage with S3Client
The text was updated successfully, but these errors were encountered: