express-cdn
Advanced tools
Comparing version 0.1.1 to 0.1.2
@@ -98,3 +98,3 @@ // express-cdn | ||
if (options.ssl) { | ||
src = 'https://' + options.domain; | ||
src = '//' + options.domain; // Allow for http request when ssl is not used | ||
} else { | ||
@@ -101,0 +101,0 @@ src = 'http://' + options.domain; |
{ | ||
"name": "express-cdn", | ||
"description": "Node.js module for delivering optimized, minified, mangled, gzipped, and CDN-hosted assets in Express using S3 and CloudFront.", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"author": { | ||
@@ -6,0 +6,0 @@ "name": "Nick Baugh", |
@@ -103,3 +103,19 @@ | ||
**SSL Configuration** | ||
Some additional steps are required to enable SSL access of your assets by cloudfront. | ||
1. Visit <https://console.aws.amazon.com/s3/home> and open the bucket's properties. | ||
2. On the permissions tab, click the add bucket policy button. | ||
* You can use the Policy Generator to generate the appropiate policy with this settings: | ||
- Type: S3 Bucket Policy | ||
- Effect: Allow | ||
- Principal: AWS | ||
- AWS Service: Amazon S3 | ||
- Actions: GetObject | ||
- ARN: arn:aws:s3:::<bucket_name>/* (fill in your bucket name) | ||
* Click on generate policy and paste the output on the add bucket policy window. | ||
* Save your changes. | ||
3. When you configure express-cdn you must reference cloudfront subdomain directly, since CNAMEs are not supported over ssl. | ||
## Quick Start | ||
@@ -352,2 +368,4 @@ | ||
* 0.1.2 - Added protocol relative paths for HTTP/HTTPS via `//` (by @Nevtep) | ||
* 0.1.1 - Add ability to specify template extension | ||
@@ -354,0 +372,0 @@ |
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
99600
441