Skip to content

Commit

Permalink
fix: CloudFront behavior for ViewerProtocolPolicy (#615)
Browse files Browse the repository at this point in the history
This was a typo in the original CloudFront L2 - this just fixes it and updates the tests for it.
  • Loading branch information
mindstorms6 authored and RomainMuller committed Aug 22, 2018
1 parent d0a3c7e commit 24ce10c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/@aws-cdk/aws-cloudfront/lib/web_distribution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export enum PriceClass {
*/
export enum ViewerProtocolPolicy {
HTTPSOnly = "https-only",
RedirectToHTTPS = "https-only",
RedirectToHTTPS = "redirect-to-https",
AllowAll = "allow-all"
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"QueryString": false
},
"TargetOriginId": "origin1",
"ViewerProtocolPolicy": "https-only"
"ViewerProtocolPolicy": "redirect-to-https"
},
"DefaultRootObject": "index.html",
"Enabled": true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"QueryString": false
},
"TargetOriginId": "origin1",
"ViewerProtocolPolicy": "https-only"
"ViewerProtocolPolicy": "redirect-to-https"
},
"DefaultRootObject": "index.html",
"Enabled": true,
Expand Down
6 changes: 3 additions & 3 deletions packages/@aws-cdk/aws-cloudfront/test/test.basic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export = {
"QueryString": false
},
"TargetOriginId": "origin1",
"ViewerProtocolPolicy": "https-only"
"ViewerProtocolPolicy": "redirect-to-https"
},
"DefaultRootObject": "index.html",
"Enabled": true,
Expand Down Expand Up @@ -150,7 +150,7 @@ export = {
"HEAD"
],
"TargetOriginId": "origin1",
"ViewerProtocolPolicy": "https-only",
"ViewerProtocolPolicy": "redirect-to-https",
"ForwardedValues": {
"QueryString": false,
"Cookies" : { "Forward" : "none"}
Expand Down Expand Up @@ -224,7 +224,7 @@ export = {
"HEAD"
],
"TargetOriginId": "origin1",
"ViewerProtocolPolicy": "https-only",
"ViewerProtocolPolicy": "redirect-to-https",
"ForwardedValues": {
"QueryString": false,
"Cookies" : { "Forward" : "none"}
Expand Down

0 comments on commit 24ce10c

Please sign in to comment.