Skip to content

Gulp Plugin to upload files to Minio S3

License

Notifications You must be signed in to change notification settings

abolkog/gulp-minio-s3

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gulp-minio-s3

Build Status

Gulp plugin to upload files to minio S3

Usage

  • Install the plugin as development dependency
npm i -D gulp-minio-s3
  • Use it in your gulpfile.js as follow
const { src, task } = require('gulp');
const minioS3 = require('gulp-minio-s3');

//Minio Configurations
const minioConfig = {
  endPoint: END_POINT_HERE,
  port: 9000,
  useSSL: false,
  accessKey: YOUR_ACCESS_KEY,
  secretKey: YOUR_SECRET_KEY
};

// S3 Bucket
const bucketName = 'my-bucker';

task('upload', () => {
  return src('./src/**').pipe(minioS3(bucketName, minioConfig));
});

task('upload-with-prefix', () => {
  return src('./src/*.css').pipe(minioS3(bucketName, minioConfig, 'css'));
});

Options

BucketName (required)

type: String

The bucket that the files will be uploaded to. Your must create the bucket beforehand. If the bucket does not exists, the plugin will throw an Error.

opts (required)

type: Object

Minio Configurations. Refer to the minio documeantion or the Minio JavaScript SDK for more details.

prefix (optional)

type: Sring

Optional param to upload files with prefix (folder) to minio

About

Gulp Plugin to upload files to Minio S3

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published