Namespace: gulpDeployS3
plugins.gulpDeployS3
Interfaces
Functions
default
▸ default(options
): Transform
Gulp plugin to upload a build into S3.
Cache control flags can be specified by either by mime-type or using matching on the file path.
File path matching takes precedence. File path matching uses the first match by array order.
Files with no rule setting will be set to immutable
.
By default, ’text/html’ type files are ’no-store’ so they will always be fetched from origin.
The plugin will generate Content-Security-Policy
compatible hashes for all inlined html
<script>
and <style>
elements and store them in the object’s metadata in S3 as
x-amz-csp-script-hashes
and x-amz-csp-style-hashes
respectively to be used in Lambda@Edge.
Make sure all ‘immutable’ files are properly cache busted with content hashes as they will be fetched by a client browser and CloudFront only once!
Parameters
Name | Type | Description |
---|---|---|
options |
S3DeployOptions |
Deploy options |
Returns
Transform