🎥 Make videos programmatically with React
enable v5 runtime flag
Jonny Burgerfdca46e317de
diff --git a/packages/docs/docs/lambda/deployfunction.mdx b/packages/docs/docs/lambda/deployfunction.mdxindex 6739756490..a70e96d3d3 100644--- a/packages/docs/docs/lambda/deployfunction.mdx+++ b/packages/docs/docs/lambda/deployfunction.mdx@@ -3,7 +3,7 @@ image: /generated/articles-docs-lambda-deployfunction.pngid: deployfunctiontitle: deployFunction()slug: /lambda/deployfunction-crumb: "Lambda API"+crumb: 'Lambda API'---Creates an [AWS Lambda](https://aws.amazon.com/lambda/) function in your AWS account that will be able to render a video in the cloud.@@ -16,10 +16,10 @@ If a function with the same version, memory size and timeout already existed, it// @module: esnext// @target: es2017-import { deployFunction } from "@remotion/lambda";+import {deployFunction} from '@remotion/lambda';-const { functionName } = await deployFunction({- region: "us-east-1",+const {functionName} = await deployFunction({+ region: 'us-east-1',timeoutInSeconds: 120,memorySizeInMb: 2048,createCloudWatchLogGroup: true,@@ -57,10 +57,10 @@ Retention period for the CloudWatch Logs. Default: 14 days.Sets the amount of disk storage that is available in the Lambda function. Must be between 512MB and 10240MB (10GB). Set this higher if you want to render longer videos. See also: [Disk size](/docs/lambda/disk-size)-| Remotion Version | Default |-|------------------|---------------|-| <5.0.0 | 2048MB |-| >=5.0.0 | 10240MB |+| Remotion Version | Default |+| ---------------- | ------- |+| <5.0.0 | 2048MB |+| >=5.0.0 | 10240MB |### `customRoleArn?`@@ -70,10 +70,6 @@ Use a custom role for the function instead of the default (`arn:aws:iam::[aws-ac<Options id="enable-lambda-insights" />-### `enableV5Runtime?`<AvailableFrom v="4.0.148" />--Enable the [upcoming v5 runtime](/docs/lambda/runtime#runtime-changes-in-remotion-50) with newer Chrome and Node versions early.-### `runtimePreference?`<AvailableFrom v="4.0.205" />One of:diff --git a/packages/docs/docs/lambda/insights.mdx b/packages/docs/docs/lambda/insights.mdxindex b9b72c03c4..35be5c5679 100644--- a/packages/docs/docs/lambda/insights.mdx+++ b/packages/docs/docs/lambda/insights.mdx@@ -2,7 +2,7 @@image: /generated/articles-docs-lambda-insights.pngsidebar_label: Insightstitle: Enable Lambda Insights-crumb: "Lambda"+crumb: 'Lambda'---# Enable Lambda Insights<AvailableFrom v="4.0.61"/>@@ -11,8 +11,13 @@ You may enable [AWS Lambda Insights](https://docs.aws.amazon.com/AmazonCloudWatc## Prerequisites-<Step>1</Step> Ensure you are on at least Remotion v4.0.61. <br/>-<Step>2</Step> If you started using Remotion before v4.0.61, update both your <a href="/docs/lambda/permissions#user-permissions">AWS user permission</a> and <a href="/docs/lambda/permissions#role-permissions">AWS role permission</a>, since now more permissions are needed.+<Step>1</Step> Ensure you are on at least Remotion v4.0.61. <br />+<Step>2</Step> If you started using Remotion before v4.0.61, update both your <a href="/docs/lambda/permissions#user-permissions">+ AWS user permission+</a> and <a href="/docs/lambda/permissions#role-permissions">+ AWS role permission+</a>+, since now more permissions are needed.## Enable Lambda Insights@@ -29,13 +34,13 @@ If the function already existed before, you need to delete it beforehand.```tsx twoslash title="deploy.ts" {8, 11-13}// @module: ESNext// @target: ESNext-import assert from "assert";+import assert from 'assert';// ---cut----import { deployFunction } from "@remotion/lambda";+import {deployFunction} from '@remotion/lambda';-const { alreadyExisted } = await deployFunction({+const {alreadyExisted} = await deployFunction({createCloudWatchLogGroup: true,- region: "us-east-1",+ region: 'us-east-1',timeoutInSeconds: 120,memorySizeInMb: 3009,enableLambdaInsights: true,@@ -67,7 +72,7 @@ If you render via the CLI with the `--log=verbose` flag, a link to the Lambda in## Unsupported regions-Lambda Insights is not supported by AWS in `ap-southeast-4`, `ap-southeast-5` and `eu-central-2`.+Lambda Insights is not supported by AWS in `ap-southeast-4` and `ap-southeast-5`.If you deploy a Lambda function in one of these regions and attempt to enable Lambda Insight, an error will be thrown.## See alsodiff --git a/packages/lambda/src/admin/make-layer-public.ts b/packages/lambda/src/admin/make-layer-public.tsindex ffbd688978..f0e34277c3 100644--- a/packages/lambda/src/admin/make-layer-public.ts+++ b/packages/lambda/src/admin/make-layer-public.ts@@ -34,7 +34,6 @@ const layerInfo: HostedLayers = {'us-west-1': [],'ap-southeast-4': [],'ap-southeast-5': [],- 'eu-central-2': [],};const getBucketName = (region: AwsRegion) => {diff --git a/packages/lambda/src/pricing/price-per-1-s.ts b/packages/lambda/src/pricing/price-per-1-s.tsindex 48019ae174..169d0353ce 100644--- a/packages/lambda/src/pricing/price-per-1-s.ts+++ b/packages/lambda/src/pricing/price-per-1-s.ts@@ -791,40 +791,7 @@ export const pricing: {price: '0.0000133334',},},- 'eu-central-2': {- 'Lambda Storage-Duration': {- rateCode: '4JZ5N4HUYM6K333N.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000000441',- },- 'Lambda Requests-ARM': {- rateCode: 'VUQUVJRYRZKGXHKX.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000002200',- },- 'Lambda Provisioned-Concurrency': {- rateCode: 'YYM4DVFSJ5APJDUG.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000055162',- },- 'Lambda Duration-ARM': {- rateCode: 'EZZMW8SEEDT6E2G5.JRTCKXETXF.6NBUNBXSC3',- price: '0.0000146667',- },- 'Lambda Requests': {- rateCode: '8FY96CH95ZA8NU5C.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000002200',- },- 'Lambda Storage-Duration-ARM': {- rateCode: 'TMSMVCZ6FWXCBNM5.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000000441',- },- 'Lambda Duration': {- rateCode: 'U6YRFNVKQZTX8VF2.JRTCKXETXF.CUKFZ388N3',- price: '0.0000183334',- },- 'Lambda Duration-Provisioned': {- rateCode: '594VMK9T4PANJ2TK.JRTCKXETXF.6YS6EN2CT7',- price: '0.0000128712',- },- },+'us-west-2': {'Lambda Duration-Provisioned': {rateCode: 'MP7NQ6MSH3HNCZP6.JRTCKXETXF.6YS6EN2CT7',diff --git a/packages/lambda/src/regions.ts b/packages/lambda/src/regions.tsindex 727c0cb2de..e7fd26aa7c 100644--- a/packages/lambda/src/regions.ts+++ b/packages/lambda/src/regions.ts@@ -20,7 +20,6 @@ export const DEFAULT_AWS_REGIONS = [export const AWS_REGIONS = ['eu-central-1',- 'eu-central-2','eu-west-1','eu-west-2','eu-west-3',diff --git a/packages/lambda/src/shared/lambda-insights-extensions.ts b/packages/lambda/src/shared/lambda-insights-extensions.tsindex 5206193096..304dced7b5 100644--- a/packages/lambda/src/shared/lambda-insights-extensions.ts+++ b/packages/lambda/src/shared/lambda-insights-extensions.ts@@ -46,5 +46,4 @@ export const lambdaInsightsExtensions: {[region in AwsRegion]: string | null} ='arn:aws:lambda:sa-east-1:580247275435:layer:LambdaInsightsExtension-Arm64:3','ap-southeast-4': null,'ap-southeast-5': null,- 'eu-central-2': null,};diff --git a/packages/template-next-app-tailwind/deploy.mjs b/packages/template-next-app-tailwind/deploy.mjsindex c8d0825190..6c4358522f 100644--- a/packages/template-next-app-tailwind/deploy.mjs+++ b/packages/template-next-app-tailwind/deploy.mjs@@ -44,7 +44,6 @@ const { functionName, alreadyExisted: functionAlreadyExisted } =region: REGION,timeoutInSeconds: TIMEOUT,diskSizeInMb: DISK,- enableV5Runtime: true,});console.log(functionName,diff --git a/packages/template-next-app/deploy.mjs b/packages/template-next-app/deploy.mjsindex 2eefb40d93..a8cbca25ba 100644--- a/packages/template-next-app/deploy.mjs+++ b/packages/template-next-app/deploy.mjs@@ -43,7 +43,6 @@ const { functionName, alreadyExisted: functionAlreadyExisted } =region: REGION,timeoutInSeconds: TIMEOUT,diskSizeInMb: DISK,- enableV5Runtime: true,});console.log(functionName,diff --git a/packages/template-next-pages/deploy.mjs b/packages/template-next-pages/deploy.mjsindex 2eefb40d93..a8cbca25ba 100644--- a/packages/template-next-pages/deploy.mjs+++ b/packages/template-next-pages/deploy.mjs@@ -43,7 +43,6 @@ const { functionName, alreadyExisted: functionAlreadyExisted } =region: REGION,timeoutInSeconds: TIMEOUT,diskSizeInMb: DISK,- enableV5Runtime: true,});console.log(functionName,diff --git a/packages/template-remix/app/deploy.ts b/packages/template-remix/app/deploy.tsindex f34f05050c..482af1f3eb 100644--- a/packages/template-remix/app/deploy.ts+++ b/packages/template-remix/app/deploy.ts@@ -21,7 +21,6 @@ const run = async () => {region,diskSizeInMb: DISK,timeoutInSeconds: TIMEOUT,- enableV5Runtime: true,});console.log(`${alreadyExisted ? "Ensured" : "Deployed"} function "${functionName}"`,