npx remotion lambda functions
The npx remotion lambda functions
command allows you to deploy, view and delete AWS lambda functions that can render videos.
You only need one function per AWS region and Remotion version. Suggested reading: Do I need to deploy a function for each render?
deploy
npx remotion lambda functions deploy
npx remotion lambda functions deploy
Creates a new function in your AWS account. If a function in the same region, with the same Remotion version, with the same amount of memory, disk space and timeout already exists, the name of the already deployed function will be returned instead.
By default, a CloudWatch Log Group will be created that will log debug information to CloudWatch that you can consult in the case something is going wrong. The default retention period for these logs is 14 days, which can be changed.
Example output
Region = eu-central-1, Memory = 2048MB, Disk = 2048MB, Timeout = 120sec, Version = 2021-12-17, CloudWatch Enabled = true, CloudWatch Retention Period = 14 days
Deployed as remotion-render-2021-12-17-2048mb-120sec
--region
The AWS region to select.
--memory
Memory size in megabytes. Default: 2048 MB.
--disk
Disk size in megabytes. Default: 2048 MB. See also: Disk size.
--timeout
Timeout of the Lambda function. Default: 120 seconds.
Not to be confused with the --timeout
flag when rendering which defines the timeout for delayRender()
.
--architecture
Architecture to be used for the Lambda. One of arm64
and x86_64
. Default: arm64.
--disable-cloudwatch
Does not create a CloudWatch log group.
--retention-period
Retention period for the CloudWatch Logs in days. Default: 14 days.
--custom-role-arn
Use a custom role for the function instead of the default (arn:aws:iam::[aws-account-id]:role/remotion-lambda-role
)
--quiet
, -q
Only logs the function name.
ls
npx remotion lambda functions ls
npx remotion lambda functions ls
Lists the functions that you have deployed to AWS in the selected region.
Example output
6 functions in the eu-central-1 region
Name Version Memory (MB) Timeout (sec)
remotion-render-2021-12-16-2048mb-240sec 2021-12-16 2048 240
remotion-render-2021-12-17-2048mb-120sec 2021-12-17 2048 120
remotion-render-2021-12-15-2048mb-240sec 2021-12-15 2048 240
--region
The AWS region to select.
--quiet
, -q
Prints only the function names in a space-separated list. If no functions exist, prints ()
rm
npx remotion lambda functions rm remotion-render-2021-12-16-2048mb-240sec
npx remotion lambda functions rm remotion-render-2021-12-16-2048mb-240sec
Removes one or more functions from your AWS infrastructure. Pass a space-separated list of functions you'd like to delete.
Example output
Function name: remotion-render-2021-12-16-2048mb-240sec
Memory: 2048MB
Timeout: 120sec
Version: 2021-12-16
Delete? (Y/n): Y
Deleted!
--region
The AWS region to select.
--yes
, -y
Skips confirmation.
rmall
npx remotion lambda functions rmall
npx remotion lambda functions rmall
Removes all functions in a region from your AWS infrastructure.
Example output
Function name: remotion-render-2021-12-16-2048mb-240sec
Memory: 2048MB
Timeout: 120sec
Version: 2021-12-16
Delete? (Y/n): Y
Deleted!
Function name: remotion-render-2021-12-18-2048mb-240sec
Memory: 2048MB
Timeout: 120sec
Version: 2021-12-16
Delete? (Y/n): Y
Deleted!
--region
The AWS region to select.
--yes
, -y
Skips confirmation.