@remotion/lambda 4.0.313 → 4.0.315

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/dist/admin/make-layer-public.js +2 -2
  2. package/dist/api/create-function.d.ts +3 -1
  3. package/dist/api/create-function.js +8 -8
  4. package/dist/api/delete-site.d.ts +3 -2
  5. package/dist/api/delete-site.js +6 -2
  6. package/dist/api/deploy-function.d.ts +3 -2
  7. package/dist/api/deploy-function.js +3 -1
  8. package/dist/api/deploy-site.d.ts +3 -1
  9. package/dist/api/deploy-site.js +7 -2
  10. package/dist/api/download-media.d.ts +2 -1
  11. package/dist/api/download-media.js +2 -0
  12. package/dist/api/get-function-info.d.ts +3 -2
  13. package/dist/api/get-function-info.js +3 -2
  14. package/dist/api/get-or-create-bucket.js +2 -1
  15. package/dist/api/iam-validation/simulate-rule.d.ts +2 -1
  16. package/dist/api/iam-validation/simulate-rule.js +1 -1
  17. package/dist/api/iam-validation/simulate.d.ts +2 -1
  18. package/dist/api/iam-validation/simulate.js +2 -1
  19. package/dist/api/upload-dir.d.ts +3 -2
  20. package/dist/api/upload-dir.js +2 -1
  21. package/dist/cli/commands/compositions/index.js +1 -0
  22. package/dist/cli/commands/functions/deploy.js +1 -0
  23. package/dist/cli/commands/quotas/increase.d.ts +2 -1
  24. package/dist/cli/commands/quotas/increase.js +5 -5
  25. package/dist/cli/commands/quotas/index.js +1 -1
  26. package/dist/cli/commands/quotas/list.js +3 -3
  27. package/dist/cli/commands/render/render.js +1 -0
  28. package/dist/cli/commands/sites/create.js +2 -0
  29. package/dist/cli/commands/sites/rm.js +1 -0
  30. package/dist/cli/commands/sites/rmall.js +1 -0
  31. package/dist/cli/commands/still.js +1 -0
  32. package/dist/cli/helpers/find-function-name.js +2 -2
  33. package/dist/cli/helpers/progress-bar.js +1 -1
  34. package/dist/esm/index.mjs +92 -57
  35. package/dist/functions/helpers/read-with-progress.d.ts +3 -2
  36. package/dist/functions/helpers/read-with-progress.js +2 -1
  37. package/dist/index.d.ts +2 -2
  38. package/dist/internals.d.ts +1 -0
  39. package/package.json +12 -12
  40. package/remotionlambda-arm64.zip +0 -0
@@ -26,14 +26,14 @@ const findFunctionName = async ({ logLevel, providerSpecifics, }) => {
26
26
  if (cliFlag) {
27
27
  const compatibleFunctionExists = lambdasWithMatchingVersion.find((l) => l.functionName === cliFlag);
28
28
  if (!compatibleFunctionExists) {
29
- log_1.Log.warn({ indent: false, logLevel }, `Function "${cliFlag}" does not match naming convention ${lambda_client_1.LambdaClientInternals.innerSpeculateFunctionName({ diskSizeInMb: '[disk]', memorySizeInMb: '[memory]', timeoutInSeconds: '[timeout]' })}.`);
29
+ log_1.Log.warn({ indent: false, logLevel }, `The name passed to --function-name "${cliFlag}" does not match the naming convention this version of the CLI expects: ${lambda_client_1.LambdaClientInternals.innerSpeculateFunctionName({ diskSizeInMb: '[disk]', memorySizeInMb: '[memory]', timeoutInSeconds: '[timeout]' })}.`);
30
30
  log_1.Log.warn({ indent: false, logLevel }, 'Remotion relies on the naming to determine function information. This is an unsupported workflow.');
31
31
  if (lambdasWithMatchingVersion.length > 0) {
32
32
  log_1.Log.info(logOptions, 'The following functions were found:');
33
33
  for (const l of lambdasWithMatchingVersion) {
34
34
  log_1.Log.info(logOptions, `- ${l.functionName} (v${l.version})`);
35
35
  }
36
- log_1.Log.info(logOptions, 'Prefer using one of those functions by passing their name to `--function-name` or removing it entirely.');
36
+ log_1.Log.info(logOptions, 'Prefer using one of those functions by passing their name to `--function-name` or removing it entirely.');
37
37
  }
38
38
  }
39
39
  return cliFlag;
@@ -5,7 +5,7 @@ const cli_1 = require("@remotion/cli");
5
5
  const no_react_1 = require("remotion/no-react");
6
6
  const makeBundleProgress = ({ progress, doneIn }) => {
7
7
  return [
8
- `${doneIn === null ? 'Bundling' : 'Bundled'} video`.padEnd(cli_1.CliInternals.LABEL_WIDTH, ' '),
8
+ `${doneIn === null ? 'Bundling' : 'Bundled'} site`.padEnd(cli_1.CliInternals.LABEL_WIDTH, ' '),
9
9
  cli_1.CliInternals.makeProgressBar(progress / 100, false),
10
10
  doneIn === null
11
11
  ? `${Math.round(progress)}%`
@@ -8604,7 +8604,7 @@ var require_package = __commonJS((exports, module) => {
8604
8604
  url: "https://github.com/remotion-dev/remotion/tree/main/packages/lambda"
8605
8605
  },
8606
8606
  name: "@remotion/lambda",
8607
- version: "4.0.313",
8607
+ version: "4.0.315",
8608
8608
  description: "Render Remotion videos on AWS Lambda",
8609
8609
  main: "dist/index.js",
8610
8610
  sideEffects: false,
@@ -8722,7 +8722,8 @@ var internalDeleteSite = async ({
8722
8722
  region,
8723
8723
  onAfterItemDeleted,
8724
8724
  providerSpecifics,
8725
- forcePathStyle
8725
+ forcePathStyle,
8726
+ requestHandler
8726
8727
  }) => {
8727
8728
  const accountId = await providerSpecifics.getAccountId({ region });
8728
8729
  let files = await providerSpecifics.listObjects({
@@ -8730,7 +8731,8 @@ var internalDeleteSite = async ({
8730
8731
  prefix: `${getSitesKey(siteName)}/`,
8731
8732
  region,
8732
8733
  expectedBucketOwner: accountId,
8733
- forcePathStyle
8734
+ forcePathStyle,
8735
+ requestHandler: null
8734
8736
  });
8735
8737
  let totalSize = 0;
8736
8738
  while (files.length > 0) {
@@ -8748,14 +8750,16 @@ var internalDeleteSite = async ({
8748
8750
  },
8749
8751
  region,
8750
8752
  providerSpecifics,
8751
- forcePathStyle
8753
+ forcePathStyle,
8754
+ requestHandler
8752
8755
  });
8753
8756
  files = await providerSpecifics.listObjects({
8754
8757
  bucketName,
8755
8758
  prefix: `${getSitesKey(siteName)}/`,
8756
8759
  region,
8757
8760
  expectedBucketOwner: accountId,
8758
- forcePathStyle
8761
+ forcePathStyle,
8762
+ requestHandler
8759
8763
  });
8760
8764
  }
8761
8765
  return {
@@ -8767,7 +8771,8 @@ var deleteSite = (props) => {
8767
8771
  ...props,
8768
8772
  onAfterItemDeleted: props.onAfterItemDeleted ?? null,
8769
8773
  forcePathStyle: props.forcePathStyle ?? false,
8770
- providerSpecifics: LambdaClientInternals.awsImplementation
8774
+ providerSpecifics: LambdaClientInternals.awsImplementation,
8775
+ requestHandler: props.requestHandler ?? null
8771
8776
  });
8772
8777
  };
8773
8778
 
@@ -9576,12 +9581,13 @@ var createFunction = async ({
9576
9581
  logLevel,
9577
9582
  vpcSubnetIds,
9578
9583
  vpcSecurityGroupIds,
9579
- runtimePreference
9584
+ runtimePreference,
9585
+ requestHandler
9580
9586
  }) => {
9581
9587
  if (createCloudWatchLogGroup) {
9582
9588
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Creating CloudWatch group");
9583
9589
  try {
9584
- await LambdaClientInternals3.getCloudWatchLogsClient(region).send(new CreateLogGroupCommand({
9590
+ await LambdaClientInternals3.getCloudWatchLogsClient(region, requestHandler).send(new CreateLogGroupCommand({
9585
9591
  logGroupName: `${LOG_GROUP_PREFIX3}${functionName}`
9586
9592
  }));
9587
9593
  RenderInternals.Log.verbose({ indent: false, logLevel }, "CloudWatch group successfully created");
@@ -9594,7 +9600,7 @@ var createFunction = async ({
9594
9600
  }
9595
9601
  }
9596
9602
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Adding retention policy to the CloudWatch group");
9597
- await LambdaClientInternals3.getCloudWatchLogsClient(region).send(new PutRetentionPolicyCommand({
9603
+ await LambdaClientInternals3.getCloudWatchLogsClient(region, requestHandler).send(new PutRetentionPolicyCommand({
9598
9604
  logGroupName: `${LOG_GROUP_PREFIX3}${functionName}`,
9599
9605
  retentionInDays
9600
9606
  }));
@@ -9621,7 +9627,7 @@ var createFunction = async ({
9621
9627
  if (enableLambdaInsights && !insightsLayer) {
9622
9628
  throw new Error(`Lambda Insights is not supported by AWS in region ${region}. Please disable Lambda Insights. See http://remotion.dev/docs/lambda/insights#unsupported-regions`);
9623
9629
  }
9624
- const { FunctionName, FunctionArn } = await LambdaClientInternals3.getLambdaClient(region).send(new CreateFunctionCommand({
9630
+ const { FunctionName, FunctionArn } = await LambdaClientInternals3.getLambdaClient(region, undefined, requestHandler).send(new CreateFunctionCommand({
9625
9631
  Code: {
9626
9632
  ZipFile: new Uint8Array(readFileSync(zipFile))
9627
9633
  },
@@ -9641,7 +9647,7 @@ var createFunction = async ({
9641
9647
  }));
9642
9648
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Function deployed. Adding tags...");
9643
9649
  try {
9644
- await LambdaClientInternals3.getLambdaClient(region).send(new TagResourceCommand({
9650
+ await LambdaClientInternals3.getLambdaClient(region, undefined, requestHandler).send(new TagResourceCommand({
9645
9651
  Resource: FunctionArn,
9646
9652
  Tags: {
9647
9653
  "remotion-lambda": "true",
@@ -9659,7 +9665,7 @@ var createFunction = async ({
9659
9665
  }
9660
9666
  }
9661
9667
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Disabling function retries (Remotion handles retries itself)...");
9662
- await LambdaClientInternals3.getLambdaClient(region).send(new PutFunctionEventInvokeConfigCommand({
9668
+ await LambdaClientInternals3.getLambdaClient(region, undefined, requestHandler).send(new PutFunctionEventInvokeConfigCommand({
9663
9669
  MaximumRetryAttempts: 0,
9664
9670
  FunctionName
9665
9671
  }));
@@ -9667,7 +9673,7 @@ var createFunction = async ({
9667
9673
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Waiting for the function to be ready...");
9668
9674
  let state = "Pending";
9669
9675
  while (state === "Pending") {
9670
- const getFn = await LambdaClientInternals3.getLambdaClient(region).send(new GetFunctionCommand({
9676
+ const getFn = await LambdaClientInternals3.getLambdaClient(region, undefined, requestHandler).send(new GetFunctionCommand({
9671
9677
  FunctionName
9672
9678
  }));
9673
9679
  await new Promise((resolve) => {
@@ -9679,7 +9685,7 @@ var createFunction = async ({
9679
9685
  RenderInternals.Log.verbose({ indent: false, logLevel }, "Locking the runtime version of the function...");
9680
9686
  const RuntimeVersionArn = `arn:aws:lambda:${region}::runtime:da57c20c4b965d5b75540f6865a35fc8030358e33ec44ecfed33e90901a27a72`;
9681
9687
  try {
9682
- await LambdaClientInternals3.getLambdaClient(region).send(new PutRuntimeManagementConfigCommand({
9688
+ await LambdaClientInternals3.getLambdaClient(region, undefined, requestHandler).send(new PutRuntimeManagementConfigCommand({
9683
9689
  FunctionName,
9684
9690
  UpdateRuntimeOn: "Manual",
9685
9691
  RuntimeVersionArn
@@ -9739,7 +9745,8 @@ var uploadDir = async ({
9739
9745
  keyPrefix,
9740
9746
  privacy,
9741
9747
  toUpload,
9742
- forcePathStyle
9748
+ forcePathStyle,
9749
+ requestHandler
9743
9750
  }) => {
9744
9751
  const files = await getFiles(localDir, localDir, toUpload);
9745
9752
  const progresses = {};
@@ -9749,7 +9756,8 @@ var uploadDir = async ({
9749
9756
  const client = LambdaClientInternals4.getS3Client({
9750
9757
  region,
9751
9758
  customCredentials: null,
9752
- forcePathStyle
9759
+ forcePathStyle,
9760
+ requestHandler
9753
9761
  });
9754
9762
  const uploadWithoutRetry = async (filePath) => {
9755
9763
  const Key = makeS3Key(keyPrefix, localDir, filePath.name);
@@ -9990,7 +9998,8 @@ var internalDeployFunction = async (params) => {
9990
9998
  logLevel: params.logLevel,
9991
9999
  vpcSubnetIds: params.vpcSubnetIds,
9992
10000
  vpcSecurityGroupIds: params.vpcSecurityGroupIds,
9993
- runtimePreference: params.runtimePreference
10001
+ runtimePreference: params.runtimePreference,
10002
+ requestHandler: null
9994
10003
  });
9995
10004
  if (!created.FunctionName) {
9996
10005
  throw new Error("Lambda was created but has no name");
@@ -10015,7 +10024,8 @@ var deployFunction = ({
10015
10024
  vpcSubnetIds,
10016
10025
  vpcSecurityGroupIds,
10017
10026
  runtimePreference,
10018
- diskSizeInMb
10027
+ diskSizeInMb,
10028
+ requestHandler
10019
10029
  }) => {
10020
10030
  if (enableV5Runtime) {
10021
10031
  console.warn("The `enableV5Runtime` option is now on by default. No need to specify it anymore.");
@@ -10035,7 +10045,8 @@ var deployFunction = ({
10035
10045
  vpcSecurityGroupIds,
10036
10046
  runtimePreference: runtimePreference ?? "default",
10037
10047
  providerSpecifics: LambdaClientInternals5.awsImplementation,
10038
- fullClientSpecifics: awsFullClientSpecifics
10048
+ fullClientSpecifics: awsFullClientSpecifics,
10049
+ requestHandler
10039
10050
  });
10040
10051
  };
10041
10052
 
@@ -10130,7 +10141,8 @@ var mandatoryDeploySite = async ({
10130
10141
  throwIfSiteExists,
10131
10142
  providerSpecifics,
10132
10143
  forcePathStyle,
10133
- fullClientSpecifics
10144
+ fullClientSpecifics,
10145
+ requestHandler
10134
10146
  }) => {
10135
10147
  LambdaClientInternals6.validateAwsRegion(region);
10136
10148
  validateBucketName({
@@ -10147,7 +10159,8 @@ var mandatoryDeploySite = async ({
10147
10159
  bucketName,
10148
10160
  region,
10149
10161
  expectedBucketOwner: accountId,
10150
- forcePathStyle
10162
+ forcePathStyle,
10163
+ requestHandler
10151
10164
  });
10152
10165
  if (!bucketExists) {
10153
10166
  throw new Error(`No bucket with the name ${bucketName} exists`);
@@ -10159,7 +10172,8 @@ var mandatoryDeploySite = async ({
10159
10172
  expectedBucketOwner: accountId,
10160
10173
  region,
10161
10174
  prefix: `${subFolder}/`,
10162
- forcePathStyle
10175
+ forcePathStyle,
10176
+ requestHandler
10163
10177
  }),
10164
10178
  fullClientSpecifics.bundleSite({
10165
10179
  publicPath: `/${subFolder}/`,
@@ -10214,7 +10228,8 @@ var mandatoryDeploySite = async ({
10214
10228
  keyPrefix: subFolder,
10215
10229
  privacy: privacy ?? "public",
10216
10230
  toUpload,
10217
- forcePathStyle
10231
+ forcePathStyle,
10232
+ requestHandler
10218
10233
  }),
10219
10234
  Promise.all(toDelete.map((d) => {
10220
10235
  return providerSpecifics.deleteFile({
@@ -10222,7 +10237,8 @@ var mandatoryDeploySite = async ({
10222
10237
  customCredentials: null,
10223
10238
  key: d.Key,
10224
10239
  region,
10225
- forcePathStyle
10240
+ forcePathStyle,
10241
+ requestHandler
10226
10242
  });
10227
10243
  }))
10228
10244
  ]);
@@ -10260,7 +10276,8 @@ var deploySite = (args) => {
10260
10276
  throwIfSiteExists: args.throwIfSiteExists ?? false,
10261
10277
  providerSpecifics: LambdaClientInternals6.awsImplementation,
10262
10278
  forcePathStyle: args.forcePathStyle ?? false,
10263
- fullClientSpecifics: awsFullClientSpecifics
10279
+ fullClientSpecifics: awsFullClientSpecifics,
10280
+ requestHandler: args.requestHandler ?? null
10264
10281
  });
10265
10282
  };
10266
10283
 
@@ -10288,12 +10305,14 @@ var lambdaDownloadFileWithProgress = async ({
10288
10305
  onProgress,
10289
10306
  customCredentials,
10290
10307
  logLevel,
10291
- forcePathStyle
10308
+ forcePathStyle,
10309
+ requestHandler
10292
10310
  }) => {
10293
10311
  const client = LambdaClientInternals7.getS3Client({
10294
10312
  region,
10295
10313
  customCredentials,
10296
- forcePathStyle
10314
+ forcePathStyle,
10315
+ requestHandler
10297
10316
  });
10298
10317
  const command = new GetObjectCommand({
10299
10318
  Bucket: bucketName,
@@ -10328,7 +10347,8 @@ var internalDownloadMedia = async (input) => {
10328
10347
  region: input.region,
10329
10348
  renderId: input.renderId,
10330
10349
  providerSpecifics: input.providerSpecifics,
10331
- forcePathStyle: input.forcePathStyle
10350
+ forcePathStyle: input.forcePathStyle,
10351
+ requestHandler: input.requestHandler
10332
10352
  });
10333
10353
  if (!overallProgress.renderMetadata) {
10334
10354
  throw new Error("Render did not finish yet");
@@ -10352,7 +10372,8 @@ var internalDownloadMedia = async (input) => {
10352
10372
  outputPath,
10353
10373
  customCredentials,
10354
10374
  logLevel: input.logLevel ?? "info",
10355
- forcePathStyle: input.forcePathStyle ?? false
10375
+ forcePathStyle: input.forcePathStyle ?? false,
10376
+ requestHandler: input.requestHandler
10356
10377
  });
10357
10378
  return {
10358
10379
  outputPath,
@@ -10377,17 +10398,19 @@ import { DEFAULT_EPHEMERAL_STORAGE_IN_MB as DEFAULT_EPHEMERAL_STORAGE_IN_MB2 } f
10377
10398
  var getFunctionInfo = async ({
10378
10399
  region,
10379
10400
  functionName,
10380
- logLevel
10401
+ logLevel,
10402
+ requestHandler
10381
10403
  }) => {
10382
10404
  LambdaClientInternals9.validateAwsRegion(region);
10383
10405
  const [functionInfo, version] = await Promise.all([
10384
- LambdaClientInternals9.getLambdaClient(region).send(new GetFunctionCommand2({
10406
+ LambdaClientInternals9.getLambdaClient(region, undefined, requestHandler).send(new GetFunctionCommand2({
10385
10407
  FunctionName: functionName
10386
10408
  })),
10387
10409
  getFunctionVersion({
10388
10410
  functionName,
10389
10411
  region,
10390
- logLevel: logLevel ?? "info"
10412
+ logLevel: logLevel ?? "info",
10413
+ requestHandler
10391
10414
  })
10392
10415
  ]);
10393
10416
  return {
@@ -10409,7 +10432,8 @@ var getOrCreateBucket = (options) => {
10409
10432
  customCredentials: options.customCredentials ?? null,
10410
10433
  providerSpecifics: LambdaClientInternals10.awsImplementation,
10411
10434
  forcePathStyle: false,
10412
- skipPutAcl: false
10435
+ skipPutAcl: false,
10436
+ requestHandler: options.requestHandler ?? null
10413
10437
  });
10414
10438
  };
10415
10439
 
@@ -10432,7 +10456,7 @@ import { SimulatePrincipalPolicyCommand } from "@aws-sdk/client-iam";
10432
10456
  import { LambdaClientInternals as LambdaClientInternals11 } from "@remotion/lambda-client";
10433
10457
  var simulateRule = async (options) => {
10434
10458
  try {
10435
- const res = await LambdaClientInternals11.getIamClient(options.region).send(new SimulatePrincipalPolicyCommand({
10459
+ const res = await LambdaClientInternals11.getIamClient(options.region, options.requestHandler).send(new SimulatePrincipalPolicyCommand({
10436
10460
  ActionNames: options.actionNames,
10437
10461
  PolicySourceArn: options.arn,
10438
10462
  ResourceArns: options.resource
@@ -10467,7 +10491,7 @@ var logPermissionOutput = (output) => {
10467
10491
  return [getEmojiForStatus(output.decision), output.name].join(" ");
10468
10492
  };
10469
10493
  var simulatePermissions = async (options) => {
10470
- const callerIdentity = await LambdaClientInternals12.getStsClient(options.region).send(new GetCallerIdentityCommand({}));
10494
+ const callerIdentity = await LambdaClientInternals12.getStsClient(options.region, options.requestHandler).send(new GetCallerIdentityCommand({}));
10471
10495
  if (!callerIdentity?.Arn) {
10472
10496
  throw new Error("No valid AWS Caller Identity detected");
10473
10497
  }
@@ -10495,7 +10519,8 @@ var simulatePermissions = async (options) => {
10495
10519
  arn: callerArn,
10496
10520
  region: options.region,
10497
10521
  resource: per.resource,
10498
- retries: 2
10522
+ retries: 2,
10523
+ requestHandler: options.requestHandler
10499
10524
  });
10500
10525
  for (const res of result) {
10501
10526
  results.push(res);
@@ -10677,7 +10702,8 @@ VPC Security Group IDs = ${vpcSecurityGroupIds}
10677
10702
  vpcSecurityGroupIds,
10678
10703
  runtimePreference,
10679
10704
  providerSpecifics,
10680
- fullClientSpecifics
10705
+ fullClientSpecifics,
10706
+ requestHandler: null
10681
10707
  });
10682
10708
  if (CliInternals3.quietFlagProvided()) {
10683
10709
  CliInternals3.Log.info({ indent: false, logLevel }, functionName);
@@ -10981,14 +11007,14 @@ var findFunctionName = async ({
10981
11007
  if (cliFlag) {
10982
11008
  const compatibleFunctionExists = lambdasWithMatchingVersion.find((l) => l.functionName === cliFlag);
10983
11009
  if (!compatibleFunctionExists) {
10984
- Log.warn({ indent: false, logLevel }, `Function "${cliFlag}" does not match naming convention ${LambdaClientInternals15.innerSpeculateFunctionName({ diskSizeInMb: "[disk]", memorySizeInMb: "[memory]", timeoutInSeconds: "[timeout]" })}.`);
11010
+ Log.warn({ indent: false, logLevel }, `The name passed to --function-name "${cliFlag}" does not match the naming convention this version of the CLI expects: ${LambdaClientInternals15.innerSpeculateFunctionName({ diskSizeInMb: "[disk]", memorySizeInMb: "[memory]", timeoutInSeconds: "[timeout]" })}.`);
10985
11011
  Log.warn({ indent: false, logLevel }, "Remotion relies on the naming to determine function information. This is an unsupported workflow.");
10986
11012
  if (lambdasWithMatchingVersion.length > 0) {
10987
11013
  Log.info(logOptions, "The following functions were found:");
10988
11014
  for (const l of lambdasWithMatchingVersion) {
10989
11015
  Log.info(logOptions, `- ${l.functionName} (v${l.version})`);
10990
11016
  }
10991
- Log.info(logOptions, "Prefer using one of those functions by passing their name to `--function-name` or removing it entirely.");
11017
+ Log.info(logOptions, "Prefer using one of those functions by passing their name to `--function-name` or removing it entirely.");
10992
11018
  }
10993
11019
  }
10994
11020
  return cliFlag;
@@ -11083,7 +11109,8 @@ var compositionsCommand = async ({
11083
11109
  envVariables,
11084
11110
  logLevel,
11085
11111
  timeoutInMilliseconds: puppeteerTimeout,
11086
- forceBucketName: parsedLambdaCli["force-bucket-name"]
11112
+ forceBucketName: parsedLambdaCli["force-bucket-name"],
11113
+ requestHandler: null
11087
11114
  });
11088
11115
  CliInternals8.printCompositions(comps, logLevel);
11089
11116
  };
@@ -11165,7 +11192,9 @@ import {
11165
11192
  ListRequestedServiceQuotaChangeHistoryByQuotaCommand,
11166
11193
  RequestServiceQuotaIncreaseCommand
11167
11194
  } from "@aws-sdk/client-service-quotas";
11168
- import { LambdaClientInternals as LambdaClientInternals17 } from "@remotion/lambda-client";
11195
+ import {
11196
+ LambdaClientInternals as LambdaClientInternals17
11197
+ } from "@remotion/lambda-client";
11169
11198
  import {
11170
11199
  BINARY_NAME as BINARY_NAME6,
11171
11200
  LAMBDA_CONCURRENCY_LIMIT_QUOTA
@@ -11178,18 +11207,18 @@ var makeQuotaUrl = ({
11178
11207
  }) => {
11179
11208
  return `https://${region}.console.aws.amazon.com/servicequotas/home/services/lambda/quotas/${quotaId}`;
11180
11209
  };
11181
- var quotasIncreaseCommand = async (logLevel) => {
11210
+ var quotasIncreaseCommand = async (logLevel, requestHandler) => {
11182
11211
  const region = getAwsRegion();
11183
11212
  const [concurrencyLimit, defaultConcurrencyLimit, changes] = await Promise.all([
11184
- LambdaClientInternals17.getServiceQuotasClient(region).send(new GetServiceQuotaCommand({
11213
+ LambdaClientInternals17.getServiceQuotasClient(region, requestHandler).send(new GetServiceQuotaCommand({
11185
11214
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA,
11186
11215
  ServiceCode: "lambda"
11187
11216
  })),
11188
- LambdaClientInternals17.getServiceQuotasClient(region).send(new GetAWSDefaultServiceQuotaCommand({
11217
+ LambdaClientInternals17.getServiceQuotasClient(region, requestHandler).send(new GetAWSDefaultServiceQuotaCommand({
11189
11218
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA,
11190
11219
  ServiceCode: "lambda"
11191
11220
  })),
11192
- LambdaClientInternals17.getServiceQuotasClient(region).send(new ListRequestedServiceQuotaChangeHistoryByQuotaCommand({
11221
+ LambdaClientInternals17.getServiceQuotasClient(region, requestHandler).send(new ListRequestedServiceQuotaChangeHistoryByQuotaCommand({
11193
11222
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA,
11194
11223
  ServiceCode: "lambda"
11195
11224
  }))
@@ -11223,7 +11252,7 @@ var quotasIncreaseCommand = async (logLevel) => {
11223
11252
  quit(1);
11224
11253
  }
11225
11254
  try {
11226
- await LambdaClientInternals17.getServiceQuotasClient(region).send(new RequestServiceQuotaIncreaseCommand({
11255
+ await LambdaClientInternals17.getServiceQuotasClient(region, requestHandler).send(new RequestServiceQuotaIncreaseCommand({
11227
11256
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA,
11228
11257
  DesiredValue: newLimit,
11229
11258
  ServiceCode: "lambda"
@@ -11259,15 +11288,15 @@ var quotasListCommand = async (logLevel) => {
11259
11288
  Log.info({ indent: false, logLevel }, CliInternals10.chalk.gray(`Region = ${region}`));
11260
11289
  Log.info({ indent: false, logLevel });
11261
11290
  const [concurrencyLimit, defaultConcurrencyLimit, changes] = await Promise.all([
11262
- LambdaClientInternals18.getServiceQuotasClient(region).send(new GetServiceQuotaCommand2({
11291
+ LambdaClientInternals18.getServiceQuotasClient(region, null).send(new GetServiceQuotaCommand2({
11263
11292
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA2,
11264
11293
  ServiceCode: "lambda"
11265
11294
  })),
11266
- LambdaClientInternals18.getServiceQuotasClient(region).send(new GetAWSDefaultServiceQuotaCommand2({
11295
+ LambdaClientInternals18.getServiceQuotasClient(region, null).send(new GetAWSDefaultServiceQuotaCommand2({
11267
11296
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA2,
11268
11297
  ServiceCode: "lambda"
11269
11298
  })),
11270
- LambdaClientInternals18.getServiceQuotasClient(region).send(new ListRequestedServiceQuotaChangeHistoryByQuotaCommand2({
11299
+ LambdaClientInternals18.getServiceQuotasClient(region, null).send(new ListRequestedServiceQuotaChangeHistoryByQuotaCommand2({
11271
11300
  QuotaCode: LAMBDA_CONCURRENCY_LIMIT_QUOTA2,
11272
11301
  ServiceCode: "lambda"
11273
11302
  }))
@@ -11307,7 +11336,7 @@ var quotasCommand = (args, logLevel) => {
11307
11336
  return quotasListCommand(logLevel);
11308
11337
  }
11309
11338
  if (args[0] === INCREASE_SUBCOMMAND) {
11310
- return quotasIncreaseCommand(logLevel);
11339
+ return quotasIncreaseCommand(logLevel, null);
11311
11340
  }
11312
11341
  CliInternals11.Log.error({ indent: false, logLevel }, "Subcommand " + args[0] + " not found.");
11313
11342
  printHelp(logLevel);
@@ -11810,7 +11839,8 @@ var renderCommand = async ({
11810
11839
  forcePathStyle: parsedLambdaCli["force-path-style"] ?? false,
11811
11840
  metadata: metadata ?? null,
11812
11841
  apiKey: parsedLambdaCli[BrowserSafeApis3.options.apiKeyOption.cliFlag] ?? null,
11813
- storageClass: parsedLambdaCli["storage-class"] ?? null
11842
+ storageClass: parsedLambdaCli["storage-class"] ?? null,
11843
+ requestHandler: null
11814
11844
  });
11815
11845
  const progressBar = CliInternals14.createOverwriteableCliOutput({
11816
11846
  quiet: CliInternals14.quietFlagProvided(),
@@ -11993,7 +12023,7 @@ import { CliInternals as CliInternals15 } from "@remotion/cli";
11993
12023
  import { NoReactInternals as NoReactInternals3 } from "remotion/no-react";
11994
12024
  var makeBundleProgress = ({ progress, doneIn }) => {
11995
12025
  return [
11996
- `${doneIn === null ? "Bundling" : "Bundled"} video`.padEnd(CliInternals15.LABEL_WIDTH, " "),
12026
+ `${doneIn === null ? "Bundling" : "Bundled"} site`.padEnd(CliInternals15.LABEL_WIDTH, " "),
11997
12027
  CliInternals15.makeProgressBar(progress / 100, false),
11998
12028
  doneIn === null ? `${Math.round(progress)}%` : CliInternals15.chalk.gray(`${doneIn}ms`)
11999
12029
  ].join(" ");
@@ -12121,7 +12151,8 @@ var sitesCreateSubcommand = async (args, remotionRoot, logLevel, implementation)
12121
12151
  customCredentials: null,
12122
12152
  providerSpecifics: implementation,
12123
12153
  forcePathStyle: false,
12124
- skipPutAcl: parsedLambdaCli.privacy === "no-acl"
12154
+ skipPutAcl: parsedLambdaCli.privacy === "no-acl",
12155
+ requestHandler: null
12125
12156
  })).bucketName;
12126
12157
  multiProgress.bucketProgress.doneIn = Date.now() - bucketStart;
12127
12158
  updateProgress(false);
@@ -12190,7 +12221,8 @@ var sitesCreateSubcommand = async (args, remotionRoot, logLevel, implementation)
12190
12221
  throwIfSiteExists,
12191
12222
  providerSpecifics: implementation,
12192
12223
  forcePathStyle: parsedLambdaCli["force-path-style"] ?? false,
12193
- fullClientSpecifics: awsFullClientSpecifics
12224
+ fullClientSpecifics: awsFullClientSpecifics,
12225
+ requestHandler: null
12194
12226
  });
12195
12227
  const uploadDuration = Date.now() - uploadStart;
12196
12228
  multiProgress.deployProgress = {
@@ -12297,7 +12329,8 @@ var sitesRmSubcommand = async (args, logLevel, implementation) => {
12297
12329
  customCredentials: null,
12298
12330
  providerSpecifics: implementation,
12299
12331
  forcePathStyle: false,
12300
- skipPutAcl: false
12332
+ skipPutAcl: false,
12333
+ requestHandler: null
12301
12334
  })).bucketName;
12302
12335
  for (const siteName of args) {
12303
12336
  const site = deployedSites.sites.find((s) => s.id === siteName.trim());
@@ -12339,7 +12372,8 @@ var sitesRmallSubcommand = async (logLevel, implementation) => {
12339
12372
  customCredentials: null,
12340
12373
  providerSpecifics: implementation,
12341
12374
  forcePathStyle: false,
12342
- skipPutAcl: false
12375
+ skipPutAcl: false,
12376
+ requestHandler: null
12343
12377
  })).bucketName;
12344
12378
  for (const site of deployedSites.sites) {
12345
12379
  if (!await confirmCli({
@@ -12607,7 +12641,8 @@ var stillCommand = async ({
12607
12641
  forcePathStyle: parsedLambdaCli["force-path-style"] ?? false,
12608
12642
  indent: false,
12609
12643
  offthreadVideoCacheSizeInBytes,
12610
- offthreadVideoThreads: null
12644
+ offthreadVideoThreads: null,
12645
+ requestHandler: null
12611
12646
  });
12612
12647
  Log.info({ indent: false, logLevel }, CliInternals21.chalk.gray(`Render ID: ${CliInternals21.makeHyperlink({ text: res.renderId, fallback: res.renderId, url: LambdaClientInternals20.getS3RenderUrl({ bucketName: res.bucketName, renderId: res.renderId, region: getAwsRegion() }) })}`));
12613
12648
  Log.info({ indent: false, logLevel }, CliInternals21.chalk.gray(`Bucket: ${CliInternals21.makeHyperlink({ text: res.bucketName, fallback: res.bucketName, url: `https://${getAwsRegion()}.console.aws.amazon.com/s3/buckets/${res.bucketName}/?region=${getAwsRegion()}` })}`));
@@ -1,4 +1,4 @@
1
- import type { AwsProvider, AwsRegion } from '@remotion/lambda-client';
1
+ import type { AwsProvider, AwsRegion, RequestHandler } from '@remotion/lambda-client';
2
2
  import type { LogLevel } from '@remotion/renderer';
3
3
  import type { CustomCredentials } from '@remotion/serverless';
4
4
  export type LambdaReadFileProgress = (progress: {
@@ -6,7 +6,7 @@ export type LambdaReadFileProgress = (progress: {
6
6
  downloaded: number;
7
7
  percent: number;
8
8
  }) => unknown;
9
- export declare const lambdaDownloadFileWithProgress: ({ bucketName, key, region, expectedBucketOwner, outputPath, onProgress, customCredentials, logLevel, forcePathStyle, }: {
9
+ export declare const lambdaDownloadFileWithProgress: ({ bucketName, key, region, expectedBucketOwner, outputPath, onProgress, customCredentials, logLevel, forcePathStyle, requestHandler, }: {
10
10
  bucketName: string;
11
11
  key: string;
12
12
  region: AwsRegion;
@@ -16,6 +16,7 @@ export declare const lambdaDownloadFileWithProgress: ({ bucketName, key, region,
16
16
  customCredentials: CustomCredentials<AwsProvider> | null;
17
17
  logLevel: LogLevel;
18
18
  forcePathStyle: boolean;
19
+ requestHandler: RequestHandler;
19
20
  }) => Promise<{
20
21
  sizeInBytes: number;
21
22
  to: string;
@@ -5,11 +5,12 @@ const client_s3_1 = require("@aws-sdk/client-s3");
5
5
  const s3_request_presigner_1 = require("@aws-sdk/s3-request-presigner");
6
6
  const lambda_client_1 = require("@remotion/lambda-client");
7
7
  const renderer_1 = require("@remotion/renderer");
8
- const lambdaDownloadFileWithProgress = async ({ bucketName, key, region, expectedBucketOwner, outputPath, onProgress, customCredentials, logLevel, forcePathStyle, }) => {
8
+ const lambdaDownloadFileWithProgress = async ({ bucketName, key, region, expectedBucketOwner, outputPath, onProgress, customCredentials, logLevel, forcePathStyle, requestHandler, }) => {
9
9
  const client = lambda_client_1.LambdaClientInternals.getS3Client({
10
10
  region,
11
11
  customCredentials,
12
12
  forcePathStyle,
13
+ requestHandler,
13
14
  });
14
15
  const command = new client_s3_1.GetObjectCommand({
15
16
  Bucket: bucketName,
package/dist/index.d.ts CHANGED
@@ -36,11 +36,11 @@ declare const renderStillOnLambda: (input: RenderStillOnLambdaInput & {
36
36
  /**
37
37
  * @deprecated Import this from `@remotion/lambda-client` instead
38
38
  */
39
- declare const presignUrl: <CheckIfObjectExists extends boolean = false>({ region, bucketName, objectKey, checkIfObjectExists, expiresInSeconds, forcePathStyle, }: import("@remotion/lambda-client").PresignUrlInput<CheckIfObjectExists>) => Promise<CheckIfObjectExists extends true ? string | null : string>;
39
+ declare const presignUrl: <CheckIfObjectExists extends boolean = false>({ region, bucketName, objectKey, checkIfObjectExists, expiresInSeconds, forcePathStyle, requestHandler, }: import("@remotion/lambda-client").PresignUrlInput<CheckIfObjectExists>) => Promise<CheckIfObjectExists extends true ? string | null : string>;
40
40
  /**
41
41
  * @deprecated Import this from `@remotion/lambda-client` instead
42
42
  */
43
- declare const getSites: ({ region, forceBucketName, forcePathStyle, }: GetSitesInput) => Promise<GetSitesOutput>;
43
+ declare const getSites: ({ region, forceBucketName, forcePathStyle, requestHandler, }: GetSitesInput) => Promise<GetSitesOutput>;
44
44
  export { deleteFunction, deleteRender, deleteSite, deployFunction, deploySite, downloadMedia, estimatePrice, getAwsClient, getCompositionsOnLambda, getFunctionInfo, getFunctions, getOrCreateBucket, getRegions, getRenderProgress, getRolePolicy, getSites, getUserPolicy, LambdaInternals, presignUrl, renderMediaOnLambda, renderStillOnLambda, renderVideoOnLambda, simulatePermissions, validateWebhookSignature, };
45
45
  export type { AwsRegion, CustomCredentials, DeleteFunctionInput, DeleteRenderInput, DeleteSiteInput, DeleteSiteOutput, DeployFunctionInput, DeployFunctionOutput, DeploySiteInput, DeploySiteOutput, DownloadMediaInput, DownloadMediaOutput, EnhancedErrorInfo, EstimatePriceInput, FunctionInfo, GetAwsClientInput, GetAwsClientOutput, GetCompositionsOnLambdaInput, GetCompositionsOnLambdaOutput, GetFunctionInfoInput, GetFunctionsInput, GetOrCreateBucketInput, GetOrCreateBucketOutput, GetRenderProgressInput, GetSitesInput, GetSitesOutput, RenderMediaOnLambdaInput, RenderMediaOnLambdaOutput, RenderProgress, RenderStillOnLambdaInput, RenderStillOnLambdaOutput, SimulatePermissionsInput, SimulatePermissionsOutput, };
46
46
  export { _InternalOverallRenderProgress };
@@ -21,6 +21,7 @@ export declare const LambdaInternals: {
21
21
  gitSource: import("@remotion/bundler").GitSource | null;
22
22
  indent: boolean;
23
23
  forcePathStyle: boolean;
24
+ requestHandler: import("@remotion/lambda-client").RequestHandler | null;
24
25
  } & import("@remotion/serverless").ToOptions<{
25
26
  readonly logLevel: {
26
27
  cliFlag: "log";
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/lambda"
4
4
  },
5
5
  "name": "@remotion/lambda",
6
- "version": "4.0.313",
6
+ "version": "4.0.315",
7
7
  "description": "Render Remotion videos on AWS Lambda",
8
8
  "main": "dist/index.js",
9
9
  "sideEffects": false,
@@ -21,13 +21,13 @@
21
21
  "@aws-sdk/lib-storage": "3.787.0",
22
22
  "@smithy/abort-controller": "4.0.1",
23
23
  "zod": "3.22.3",
24
- "@remotion/bundler": "4.0.313",
25
- "@remotion/lambda-client": "4.0.313",
26
- "@remotion/renderer": "4.0.313",
27
- "@remotion/streaming": "4.0.313",
28
- "@remotion/serverless": "4.0.313",
29
- "remotion": "4.0.313",
30
- "@remotion/cli": "4.0.313"
24
+ "@remotion/bundler": "4.0.315",
25
+ "@remotion/cli": "4.0.315",
26
+ "@remotion/renderer": "4.0.315",
27
+ "@remotion/lambda-client": "4.0.315",
28
+ "@remotion/serverless": "4.0.315",
29
+ "@remotion/streaming": "4.0.315",
30
+ "remotion": "4.0.315"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@types/express": "^5.0.0",
@@ -40,12 +40,12 @@
40
40
  "next": "15.2.4",
41
41
  "pureimage": "0.4.13",
42
42
  "zip-lib": "^0.7.2",
43
- "@remotion/bundler": "4.0.313",
44
- "@remotion/eslint-config-internal": "4.0.313",
45
- "@remotion/compositor-linux-arm64-gnu": "4.0.313"
43
+ "@remotion/bundler": "4.0.315",
44
+ "@remotion/compositor-linux-arm64-gnu": "4.0.315",
45
+ "@remotion/eslint-config-internal": "4.0.315"
46
46
  },
47
47
  "peerDependencies": {
48
- "@remotion/bundler": "4.0.313"
48
+ "@remotion/bundler": "4.0.315"
49
49
  },
50
50
  "publishConfig": {
51
51
  "access": "public"
Binary file