storage
storage copied to clipboard
Connect storage to external AWS S3 bucket
Improve documentation
Link
https://github.com/supabase/storage-api
Describe the problem
We want to help everybody who wants to hosting their own storage module. In our case, we need to connect a k8s self hosted supabase deployment with an AWS S3 bucket. When we surfing the documentation, we facing at a link to how we can create a IAM User to access through aws-cli or aws-sdk, but we never read about how we can configure the storage container.
We take a look at the code searching for something like AWS_ACCESS_ID, or SECRET_ID but nothing comes up. After that, I understand that we have to "upload" a credentials
file to the container in order to authenticate aws-sdk commands.
And finally, we found the solution!
Describe the improvement
You have to save a credentials
file at /root/.aws
in the storage container to be authenticated.
You have to upload a file at /root/.aws/credentials
with:
[default]
aws_access_key_id = xxxxxxxxxxxxxxxxxxxxx
aws_secret_access_key = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Additional context
Can we also choose our own endpoint?
Hey, What's about the AWS CLI? Shoul I go manually inside the container to download it and set the credentials ? I think this method isn't the best ...
You can use any mechanism supported by the aws sdk, which are documented at https://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/configuring-the-jssdk.html
In this specific scenario, you could use e.g. environment variables on your container definition. Or if you're using EKS, you can use https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html as well.
You can use any mechanism supported by the aws sdk, which are documented at https://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/configuring-the-jssdk.html
In this specific scenario, you could use e.g. environment variables on your container definition. Or if you're using EKS, you can use https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html as well.
I am also looking on using a self-hosted S3 backend, like mini.io. How would I proceed with your information? Can anyone elaborate further on that?
Improve documentation
Link
https://github.com/supabase/storage-api
Describe the problem
We want to help everybody who wants to hosting their own storage module. In our case, we need to connect a k8s self hosted supabase deployment with an AWS S3 bucket. When we surfing the documentation, we facing at a link to how we can create a IAM User to access through aws-cli or aws-sdk, but we never read about how we can configure the storage container.
We take a look at the code searching for something like AWS_ACCESS_ID, or SECRET_ID but nothing comes up. After that, I understand that we have to "upload" a
credentials
file to the container in order to authenticate aws-sdk commands.And finally, we found the solution!
Describe the improvement
You have to save a
credentials
file at/root/.aws
in the storage container to be authenticated. You have to upload a file at/root/.aws/credentials
with:[default] aws_access_key_id = xxxxxxxxxxxxxxxxxxxxx aws_secret_access_key = xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Additional context
Thank you! this wasn't documented anywhere that I could find. I never would have figured this out.
Why does it seem they are removing self-hosting documentation? I can find less about self-hosting now than I could a few months ago.
Thank you! this wasn't documented anywhere that I could find. I never would have figured this out.
Why does it seem they are removing self-hosting documentation? I can find less about self-hosting now than I could a few months ago.
money. they're launching. they probaply don't want stakeholders asking questions about people leaving the platform and not paying them :D
We rebuilt the docs website from ground up recently. Appreciate the feedback, will share with the team that the self hosting docs aren't discoverable in the new site.
We encourage folks to self host if the hosted platform doesn't meet their requirements. We recently added storage to the self hosted dashboard and even new features like the image transformations feature are already available in the self hosted version. In fact, there are features like rate limiting and webhooks support for storage where the platform version lags the self hosted version.
Let's make the self-hosting docs more visible ⚡️ We're going to move all the self-hosting docs into their own top-level section on the Docs website and start adding all the relevant information there.
Started the move https://github.com/supabase/supabase/pull/11098
Awesome! Didn't expect to get any sort of response. The new Docs site does look great!
@captainR0bbo Just merged it
Thank you!