deploy-azure-cdn
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -7,3 +7,4 @@ "use strict"; | ||
deleteBlob: jest.fn(), | ||
createBlockBlobFromLocalFile: jest.fn() | ||
createBlockBlobFromLocalFile: jest.fn(), | ||
withFilter: jest.fn(), | ||
}; | ||
@@ -14,3 +15,6 @@ | ||
return mocks; | ||
} | ||
}, | ||
ExponentialRetryPolicyFilter: jest.fn().mockImplementation(() => {return jest.fn()}), | ||
LinearRetryPolicyFilter: jest.fn().mockImplementation(() => {return jest.fn()}), | ||
RetryPolicyFilter: jest.fn().mockImplementation(() => {return jest.fn()}) | ||
}; |
{ | ||
"name": "deploy-azure-cdn", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "A package that copies files to Azure CDN. Can be used as gulp task.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -42,2 +42,3 @@ # deploy-azure-cdn | ||
zip: true, // gzip files if they become smaller after zipping, content-encoding header will change if file is zipped | ||
filters: [new azure.ExponentialRetryPolicyFilter()], | ||
metadata: {cacheControl: 'public, max-age=31556926'}, // metadata for each uploaded file | ||
@@ -63,2 +64,3 @@ testRun: false // test run - means no blobs will be actually deleted or uploaded, see log messages for details | ||
- `zip`: false, // true if want to gzip the files before uploading. File will be zipped only if compressed file is smaller than original | ||
- `filters`: `<azure.IFilter>[]`, // list of filters to apply to blob service. | ||
- `metadata`: {cacheControl: 'public, max-age=31556926'} // metadata for each uploaded file | ||
@@ -65,0 +67,0 @@ - `testRun`: false, // set to true if you just want to check connectivity and see deployment logs. No blobs will be removed or uplaoded. |
@@ -161,2 +161,3 @@ "use strict"; | ||
concurrentUploadThreads: 10, // number of concurrent uploads, choose best for your network condition | ||
filters: [], // list of filters to apply to blob service. | ||
zip: false, // gzip files if they become smaller after zipping, content-encoding header will change if file is zipped | ||
@@ -171,2 +172,6 @@ metadata: {cacheControl: 'public, max-age=31556926'}, // metadata for each uploaded file | ||
if(options.filters && options.filters.length) { | ||
options.filters.forEach(blobService.withFilter); | ||
} | ||
var createFolderAndClearPromise = createAzureCdnContainer(blobService, options). | ||
@@ -220,1 +225,7 @@ then(function () { | ||
}; | ||
module.exports.filters = { | ||
ExponentialRetryPolicyFilter: new azure.ExponentialRetryPolicyFilter(), | ||
LinearRetryPolicyFilter : new azure.LinearRetryPolicyFilter(), | ||
RetryPolicyFilter : new azure.RetryPolicyFilter() | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
55111
952
83