Skip to content

Instantly share code, notes, and snippets.

@wipiano
Created May 15, 2019 03:39
Show Gist options
  • Save wipiano/64f81fac0e781cde5e222b7564bea2af to your computer and use it in GitHub Desktop.
Save wipiano/64f81fac0e781cde5e222b7564bea2af to your computer and use it in GitHub Desktop.
lambda @edge redirect sample
exports.handler = (event, context, callback) => {
const response = {
status: '302',
statusDescription: 'Found',
headers: {
location: [{
key: 'Location',
value: '{url}',
}],
},
};
callback(null, response);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment