{
"uris":[
{
"original":"/index1.html",
"redirect":"/index2.html?test=1",
"statusCode":"302",
"startTime":"2017-10-23T13:15",
"endTime":""
}],
"wildcards":[
{
"original":"/index6/*",
"redirect":"/index7/*",
"statusCode":"301",
"startTime":"2017-10-23T01:01",
"endTime":"2017-10-25T01:01"
}],
"querystrings":[
{
"original":"campaign=1",
"redirect":"/index4.html?test",
"statusCode":"301",
"startTime":"",
"endTime":""
}]
}
this.ruleset.rules
to
this.ruleset.uris
Following this guide:
https://aws.amazon.com/blogs/networking-and-content-delivery/handling-redirectsedge-part2/
Recommends a JSON like this one:
But that json is wrong,
Two possible options:
Change the json in the doc to modify the "uris" key and name it "rules"
Change the code so in this line:
aws-lambda-redirection-at-edge/lambda/origin-request-function/rules.js
Line 31 in 73b0876
rename from:
Other than that, thanks for this example :D