Skip to content

🎥 Make videos programmatically with React

runtime preference

Jonny Burger002712d828b4
diff --git a/packages/docs/docs/lambda/cli/functions.mdx b/packages/docs/docs/lambda/cli/functions.mdx
index a81ed58c62..9b62fd68e4 100644
--- a/packages/docs/docs/lambda/cli/functions.mdx
+++ b/packages/docs/docs/lambda/cli/functions.mdx
@@ -72,8 +72,8 @@ Disk size in megabytes. See also: [Disk size](/docs/lambda/disk-size).
Timeout of the Lambda function. Default: <DefaultTimeout /> seconds.
-:::info
-Not to be confused with the [`--timeout` flag when rendering which defines the timeout for `delayRender()`](/docs/cli/render#--timeout).
+:::note
+Not to be confused with the [`--timeout` flag for `npx remotion lambda render` which defines the timeout for `delayRender()`](/docs/cli/render#--timeout).
:::
### `--disable-cloudwatch`
@@ -108,6 +108,14 @@ Comma separated list of VPC subnet IDs to use for the Lambda function VPC config
Comma separated list of VPC security group IDs to use for the Lambda function VPC configuration.
+### `--runtime-preference`<AvailableFrom v="4.0.205" />
+
+One of:
+
+- `default`: Currently resolving to `prefer-cjk`
+- `prefer-apple-emojis`: Use Apple Emojis instead of Google Emojis. CJK characters will be removed.
+- `prefer-cjk`: Include CJK (Chinese, Japanese, Korean) characters and Google Emojis. Apple Emojis will be removed.
+
## ls
```
diff --git a/packages/docs/docs/lambda/custom-layers.mdx b/packages/docs/docs/lambda/custom-layers.mdx
index 4c6f852e76..6c8985d8fb 100644
--- a/packages/docs/docs/lambda/custom-layers.mdx
+++ b/packages/docs/docs/lambda/custom-layers.mdx
@@ -13,14 +13,42 @@ The Lambda function [includes Chrome and base fonts by default](/docs/lambda/run
In some advanced use cases, you want to replace certain parts of the stack:
- Use another Chrome version (you may need to [build it yourself](https://github.com/remotion-dev/chrome-build-instructions/tree/main))
-- Replace default fonts or emojis (such as [Apple Emoji font](https://github.com/samuelngs/apple-emoji-linux))
+- Replace default fonts or emojis
Before you create a custom stack, feel free to contact us to see if Remotion can provide the changes upstream.
-Also consider that the AWS Lambda layers may not exceed 250MB extracted, so you need to sacrifice an equal amount of other files.
+Also consider that the AWS Lambda layers cumulatively may not exceed 250MB extracted, so you need to sacrifice an equal amount of other files.
If you just want to add fonts, we recommend to use [Web fonts](/docs/fonts) instead.
+## Default layers<AvailableFrom v="4.0.205"/>
+
+Consider using our layer options before creating a custom stack:
+
+With the default option (`--runtime-preference=cjk` or no option):
+
+| Item | Size |
+|--------------|--------|
+| chromium | 188 MB |
+| emoji-google | 9.9 MB |
+| fonts | 1.9 MB |
+| cjk | 16 MB |
+| **Total** | 215.8 MB |
+
+With the option [`--runtime-preference=apple-emojis`](/docs/lambda/deployfunction#runtimepreference):
+
+| Item | Size |
+|--------------|--------|
+| chromium | 188 MB |
+| emoji-apple | 45 MB |
+| fonts | 1.9 MB |
+| **Total** | 235.9 MB |
+
+:::note
+Note that by enabling the Apple Emojis, to stay under the 250 MB limit, support for CJK (Chinese, Japanese, Korean) characters will be removed.
+Google Emojis are also removed.
+:::
+
## Ensure Remotion version
Customizing Remotion Lambda Layers is possible from v3.0.17.
diff --git a/packages/docs/docs/lambda/deployfunction.mdx b/packages/docs/docs/lambda/deployfunction.mdx
index df186e2ee0..c1f178ce22 100644
--- a/packages/docs/docs/lambda/deployfunction.mdx
+++ b/packages/docs/docs/lambda/deployfunction.mdx
@@ -45,21 +45,15 @@ We recommend a timeout of 120 seconds or lower - remember, Remotion Lambda is th
How many megabytes of RAM the Lambda function should have. By default we recommend a value of 2048MB. You may increase or decrease it depending on how memory-consuming your video is. The minimum allowed number is `512`, the maximum allowed number is `10240`. Since the costs of Remotion Lambda is directly proportional to the amount of RAM, we recommend to keep this amount as low as possible.
-### `createCloudWatchLogGroup`
-
-_boolean_
+### `createCloudWatchLogGroup?`
Whether logs should be saved into CloudWatch. We recommend enabling this option.
-### `cloudWatchLogRetentionPeriodInDays`
-
-_optional_
+### `cloudWatchLogRetentionPeriodInDays?`
Retention period for the CloudWatch Logs. Default: 14 days.
-### `diskSizeInMb`
-
-_optional_
+### `diskSizeInMb?`
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)
@@ -68,24 +62,26 @@ Sets the amount of disk storage that is available in the Lambda function. Must b
| &lt;5.0.0 | 2048MB |
| &gt;=5.0.0 | 10240MB |
-### `customRoleArn`
-
-_optional_
+### `customRoleArn?`
Use a custom role for the function instead of the default (`arn:aws:iam::[aws-account-id]:role/remotion-lambda-role`)
-### `enableLambdaInsights`<AvailableFrom v="4.0.61" />
-
-_optional_
+### `enableLambdaInsights?`<AvailableFrom v="4.0.61" />
<Options id="enable-lambda-insights" />
-### `enableV5Runtime`<AvailableFrom v="4.0.148" />
-
-_optional_
+### `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:
+
+- `default`: Currently resolving to `prefer-cjk`
+- `prefer-apple-emojis`: Use Apple Emojis instead of Google Emojis. CJK characters will be removed.
+- `prefer-cjk`: Include CJK (Chinese, Japanese, Korean) characters and Google Emojis. Apple Emojis will be removed.
+
## Return value
An object with the following values:
@@ -96,6 +92,6 @@ An object with the following values:
## See also
- [Source code for this function](https://github.com/remotion-dev/remotion/blob/main/packages/lambda/src/api/deploy-function.ts)
-- [CLI equivalent: npx remotion lambda functions deploy](/docs/lambda/cli/functions#deploy)
-- [deleteFunction()](/docs/lambda/deletefunction)
-- [getFunctions()](/docs/lambda/getfunctions)
+- [CLI equivalent: `npx remotion lambda functions deploy`](/docs/lambda/cli/functions#deploy)
+- [`deleteFunction()`](/docs/lambda/deletefunction)
+- [`getFunctions()`](/docs/lambda/getfunctions)