@remotion/lambda 3.3.19 → 3.3.25

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.
@@ -4,12 +4,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const bundler_1 = require("@remotion/bundler");
7
+ const compositor_linux_arm64_musl_1 = require("@remotion/compositor-linux-arm64-musl");
8
+ const compositor_linux_x64_musl_1 = require("@remotion/compositor-linux-x64-musl");
7
9
  const fs_1 = __importDefault(require("fs"));
8
10
  const path_1 = __importDefault(require("path"));
9
11
  const quit_1 = require("../cli/helpers/quit");
10
12
  const function_zip_path_1 = require("../shared/function-zip-path");
11
13
  const zl = require("zip-lib");
12
- const bundleLambda = async () => {
14
+ const bundleLambda = async (arch) => {
13
15
  var _a;
14
16
  const outdir = path_1.default.join(__dirname, '..', `build-render`);
15
17
  fs_1.default.mkdirSync(outdir, {
@@ -26,13 +28,27 @@ const bundleLambda = async () => {
26
28
  outfile,
27
29
  entryPoints: [template],
28
30
  treeShaking: true,
31
+ external: ['./compositor', './compositor.exe'],
29
32
  });
30
- await zl.archiveFolder(outdir, function_zip_path_1.FUNCTION_ZIP);
33
+ const compositorFile = `${outdir}/compositor`;
34
+ if (arch === 'arm64') {
35
+ fs_1.default.copyFileSync(compositor_linux_arm64_musl_1.binaryPath, compositorFile);
36
+ await zl.archiveFolder(outdir, function_zip_path_1.FUNCTION_ZIP_ARM64);
37
+ }
38
+ else {
39
+ fs_1.default.copyFileSync(compositor_linux_x64_musl_1.binaryPath, compositorFile);
40
+ await zl.archiveFolder(outdir, function_zip_path_1.FUNCTION_ZIP_X86_64);
41
+ }
42
+ fs_1.default.unlinkSync(compositorFile);
31
43
  fs_1.default.unlinkSync(outfile);
32
44
  };
33
- bundleLambda()
45
+ bundleLambda('arm64')
34
46
  .then(() => {
35
- console.log('Lambda bundled');
47
+ console.log('Lambda bundled for arm64');
48
+ return bundleLambda('x86_64');
49
+ })
50
+ .then(() => {
51
+ console.log('Lambda bundled for x86_64');
36
52
  })
37
53
  .catch((err) => {
38
54
  console.log(err);
@@ -55,7 +55,9 @@ const deployFunction = async (options) => {
55
55
  const created = await (0, create_function_1.createFunction)({
56
56
  createCloudWatchLogGroup: options.createCloudWatchLogGroup,
57
57
  region: options.region,
58
- zipFile: function_zip_path_1.FUNCTION_ZIP,
58
+ zipFile: options.architecture === 'arm64'
59
+ ? function_zip_path_1.FUNCTION_ZIP_ARM64
60
+ : function_zip_path_1.FUNCTION_ZIP_X86_64,
59
61
  functionName: fnNameRender,
60
62
  accountId,
61
63
  memorySizeInMb: options.memorySizeInMb,
@@ -3,6 +3,6 @@ declare type Options = {
3
3
  expectedBucketOwner: string;
4
4
  };
5
5
  export declare const compositionsHandler: (lambdaParams: LambdaPayload, options: Options) => Promise<{
6
- compositions: import("remotion").TCompMetadata[];
6
+ compositions: import("remotion/.").TCompMetadata[];
7
7
  }>;
8
8
  export {};
@@ -1 +1 @@
1
- export declare const getCurrentRegionInFunction: () => "eu-central-1" | "eu-west-1" | "eu-west-2" | "eu-west-3" | "eu-north-1" | "us-east-1" | "us-east-2" | "us-west-1" | "us-west-2" | "ap-south-1" | "ap-southeast-1" | "ap-southeast-2" | "ap-northeast-1" | "ap-northeast-2" | "ap-northeast-3" | "ca-central-1" | "sa-east-1" | "eu-south-1" | "af-south-1" | "ap-east-1" | "me-south-1";
1
+ export declare const getCurrentRegionInFunction: () => "eu-central-1" | "eu-west-1" | "eu-west-2" | "eu-west-3" | "eu-south-1" | "eu-north-1" | "us-east-1" | "us-east-2" | "us-west-1" | "us-west-2" | "af-south-1" | "ap-south-1" | "ap-east-1" | "ap-southeast-1" | "ap-southeast-2" | "ap-northeast-1" | "ap-northeast-2" | "ap-northeast-3" | "ca-central-1" | "me-south-1" | "sa-east-1";
@@ -1 +1,2 @@
1
- export declare const FUNCTION_ZIP: string;
1
+ export declare const FUNCTION_ZIP_ARM64: string;
2
+ export declare const FUNCTION_ZIP_X86_64: string;
@@ -3,6 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.FUNCTION_ZIP = void 0;
6
+ exports.FUNCTION_ZIP_X86_64 = exports.FUNCTION_ZIP_ARM64 = void 0;
7
7
  const path_1 = __importDefault(require("path"));
8
- exports.FUNCTION_ZIP = path_1.default.join(path_1.default.resolve(__dirname, '..', '..'), `remotionlambda.zip`);
8
+ exports.FUNCTION_ZIP_ARM64 = path_1.default.join(path_1.default.resolve(__dirname, '..', '..'), `remotionlambda-arm64.zip`);
9
+ exports.FUNCTION_ZIP_X86_64 = path_1.default.join(path_1.default.resolve(__dirname, '..', '..'), `remotionlambda-x64.zip`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remotion/lambda",
3
- "version": "3.3.19",
3
+ "version": "3.3.25",
4
4
  "description": "Distributed renderer for Remotion based on AWS Lambda",
5
5
  "main": "dist/index.js",
6
6
  "sideEffects": false,
@@ -33,12 +33,12 @@
33
33
  "@aws-sdk/credential-providers": "3.215.0",
34
34
  "@aws-sdk/lib-storage": "3.215.0",
35
35
  "@aws-sdk/s3-request-presigner": "3.215.0",
36
- "@remotion/bundler": "3.3.19",
37
- "@remotion/cli": "3.3.19",
38
- "@remotion/renderer": "3.3.19",
36
+ "@remotion/bundler": "3.3.25",
37
+ "@remotion/cli": "3.3.25",
38
+ "@remotion/renderer": "3.3.25",
39
39
  "aws-policies": "^1.0.1",
40
40
  "mime-types": "2.1.34",
41
- "remotion": "3.3.19"
41
+ "remotion": "3.3.25"
42
42
  },
43
43
  "peerDependencies": {
44
44
  "react": ">=16.8.0",
@@ -46,6 +46,8 @@
46
46
  },
47
47
  "devDependencies": {
48
48
  "@jonny/eslint-config": "3.0.266",
49
+ "@remotion/compositor-linux-arm64-musl": "3.3.25",
50
+ "@remotion/compositor-linux-x64-musl": "3.3.25",
49
51
  "@types/mime-types": "2.1.1",
50
52
  "@types/minimist": "1.2.2",
51
53
  "@types/node": "^14.14.14",
@@ -61,5 +63,5 @@
61
63
  "publishConfig": {
62
64
  "access": "public"
63
65
  },
64
- "gitHead": "097ff40cd34ecba3c7ebbbc08b442827b0f4ad7d"
66
+ "gitHead": "48e46dd2ede8fe903bf0139cebd6f546d7f2b5e0"
65
67
  }
Binary file
Binary file
Binary file