0.1.7 • Published 3 months ago

medusa-storage-supabase v0.1.7

Weekly downloads
-
License
GPL-3.0-only
Repository
github
Last release
3 months ago

medusa-storage-supabase

Handle file uploads with supabase

Medusa Website | Medusa Repository

Features

  • Upload files to assets/ and private files to private/.
  • Get file signed url
  • Delete file

Prerequisites


How to Install

1. Run the following command in the directory of the Medusa backend:

npm install medusa-storage-supabase

2. Set the following environment variables in .env:

STORAGE_BUCKET_REF=<found in the settings>
STORAGE_SERVICE_KEY=<this is the service role key, not the public>
BUCKET_NAME=<bucket name>

3. In medusa-config.js add the following at the end of the plugins array:

const plugins = [
  // ...
  {
    resolve: `medusa-storage-supabase`,
    options: {
      referenceID: process.env.STORAGE_BUCKET_REF,
      serviceKey: process.env.STORAGE_SERVICE_KEY,
      bucketName: process.env.BUCKET_NAME,
    },
  },
];

Test the Plugin

1. Run the following command in the directory of the Medusa backend to run the backend:

npm start

2. Try to change a product image.


Additional Resources

0.1.7

3 months ago

0.1.4

3 months ago

0.1.6

3 months ago

0.1.5

3 months ago

0.1.0

3 months ago

0.1.2

3 months ago

0.1.1

3 months ago

0.1.3

3 months ago

0.0.9

3 months ago

0.0.6

3 months ago

0.0.5

3 months ago

0.0.4

3 months ago

0.0.3

3 months ago

0.0.2

3 months ago

0.0.1

3 months ago