gulp-s3-deploy
A Gulp plugin that deploys your files to an Amazon AWS S3 bucket.
Last updated 5 years ago by kristoph .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install gulp-s3-deploy 
SYNC missed versions from official npm registry.

gulp-s3-deploy

An Amazon AWS S3 deployment plugin for gulp

Install

Add gulp-s3-deploy as a development dependency:

npm install --save-dev gulp-s3-deploy

Usage

Configure your credentials and bucket:

var s3Credentials = {
  "key":    "AKIAI3Z7CUAFHG53DMJA",
  "secret": "acYxWRu5RRa6CwzQuhdXEfTpbQA+1XQJ7Z1bGTCx",
  "bucket": "dev.example.com",
  "region": "eu-west-1"
};

In your gulp task, deploy your files:

var s3 = require( "gulp-s3" );
gulp.src( './public/**' )
    .pipe( s3( s3Credentials ) );

API

options.headers

Type: Array
Default: []

Headers to set to each file uploaded to S3

var options = { headers: {'Cache-Control': 'max-age=315360000, no-transform, public'} }
gulp.src('./dist/**', {read: false})
    .pipe(s3(aws, options));

options.gzStrip

Type: Boolean Default: false

If set the gz extension of files will be removed.

options.gzOnly

Type: Boolean
Default: false

If set, only files with a gz extension will be uploaded.

License

MIT License [npm-url]: https://npmjs.org/package/gulp-s3-deploy

Current Tags

  • 1.0.1                                ...           latest (5 years ago)

2 Versions

  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (5)
Dev Dependencies (0)
None
Dependents (1)

Copyright 2014 - 2017 © taobao.org |