github RJPearson94/terraform-aws-open-next v3.0.0

latest release: v3.0.1
one month ago

Support for Open Next V3 🎉 🚀

Version 3 of the module supports many of the features released as part of Open Next v2 and V3, including:

  • Support for function splitting
  • Support for external middleware (Only Lambda@edge is supported)
  • Support for open-next.output.json configuration file
  • Support for server actions
  • Support for ISR revalidation
  • Support for Image Optimisation

NOTE: Open Next v3 introduced additional deployment targets. This module only supports hosting resources in lambda and lambda@edge; running resources on Cloudflare, ECS, etc., is not supported.

Where possible, the modules try to give you as many configuration options as possible; however, the module won't be able to cater to all use cases. For the majority of components, you can curate your bespoke resources in Terraform, i.e. WAF, CloudFront distribution, etc., and pass the ARN of the resource to the module to use.

Upgrading

From 2.x to 3.x

The module has been made backwards compatible with 2.x where possible.

For open next v3, the module will read the open-next.output.json file in the .open-next directory to determine the edge and server functions that need to be configured, as well as any default configuration, e.g., streaming.

NOTE: Deprecated fields have been removed. If you use one of the following values, you will need to modify your Terraform/ Terragrunt configuration

  • The EDGE_LAMBDA backend deployment type is no longer supported for server function. In open next v3, this has been moved into edge functions instead [BREAKING CHANGE]
  • aws_lambda_permission.server_function_url_permission and aws_lambda_permission.image_optimisation_function_url_permission have been merged into a list of aws_lambda_permission.function_url_permission resources in the tf-aws-open-next-multi-zone module. You can either let the resources re-create or update the references using either move config, import block or import command [BREAKING CHANGE]
  • CloudFront cache policy ARN - you must now set the CloudFront Cache Policy ID
  • Auth function CloudFront log group - this configuration had no effect, so it has been removed
  • Lambda Logging configuration (for regional lambda's only) [NEW FEATURE]
  • Additional configuration of CloudWatch log groups, including having a log group for all regional functions in a zone [NEW FEATURE]

If you are still using open next v2.x, you can set the open_next_version variable to v2.x.x (the default value). If you upgrade to Open Next v3.x, please set the open_next_version variable to v3.x.x.

If you want to migrate from Open Next v2 to v3, see the migration guide, which the Open Next team created.

Don't miss a new terraform-aws-open-next release

NewReleases is sending notifications on new releases.