gulp-azure-storage

    0.12.1 • Public • Published

    gulp-azure-storage

    Gulp plugin to download and upload files to/from the Azure blob storage.

    Installation

    npm install gulp-azure-storage
    

    Usage

    Upload

    Simply pipe in a gulp stream:

    gulp.task(['default'], function() { 
      return gulp.src('bin/**')
        .pipe(azure.upload({
        	account:    ACCOUNT_NAME,
        	key:        ACCOUNT_KEY,
        	container:  CONTAINER_NAME
        }));
    });

    Download

    Simply use it as a gulp source stream:

    var gulp = require('gulp');
    var azure = require('gulp-azure-storage');
    
    gulp.task(['default'], function() {
      return azure.download({
      	account:    ACCOUNT_NAME,
      	key:        ACCOUNT_KEY,
      	container:  CONTAINER_NAME
      }).pipe(gulp.dest('out'));
    });

    CLI

    There's a script included with the module that allows you to upload some files to an azure container:

    $ upload-to-azure \
      --account ACCOUNT_NAME \
      --key ACCOUNT_KEY \
      --container CONTAINER_NAME \
      file1.txt \
      file2.txt

    Options

    Mandatory:

    • account
    • container

    Optional:

    • key - container will be accessed anonymously, if missing
    • prefix - blob name prefix
    • quiet - shhh
    • buffer - boolean for whether to buffer the blobs or stream them (only for download)

    Install

    npm i gulp-azure-storage

    DownloadsWeekly Downloads

    4,209

    Version

    0.12.1

    License

    MIT

    Unpacked Size

    8.65 kB

    Total Files

    7

    Last publish

    Collaborators

    • jrieken
    • joaomoreno
    • alexandrudima
    • dbaeumer
    • bpasero
    • joaomoreno.ms