Skip to content

liashchynskyi/strapi-provider-upload-s3-cloudfront

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Why?

This plugin is based on https://www.npmjs.com/package/@strapi/provider-upload-aws-s3 with the ability to serve files from Cloudfront. Built with @aws-sdk/client-s3.

Installation

npm install @liashchynskyi/strapi-provider-upload-s3-cloudfront
# or
yarn add @liashchynskyi/strapi-provider-upload-s3-cloudfront

Configuration

All available configs.

// config/plugins.ts

import { S3ConfigOptions } from '@liashchynskyi/strapi-provider-upload-s3-cloudfront'

export default ({ env }) => ({
  upload: {
    config: {
      provider: '@liashchynskyi/strapi-provider-upload-s3-cloudfront',
      providerOptions: {
        credentials: {
          accessKeyId: env('AWS_ACCESS_KEY_ID'),
          secretAccessKey: env('AWS_SECRET_ACCESS_KEY'),
        },
        region: env('AWS_S3_BUCKET_LOCATION'),
        bucket: env('AWS_S3_BUCKET_PREFIX'),
        cdn: env('AWS_CLOUDFRONT_DOMAIN'),
      },
    },
  },
});

About

Strapi AWS S3 upload plugin with the ability to serve from Cloudfront

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published