@remotion/lambda 4.0.499 → 4.0.500
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.
- package/dist/api/deploy-site.js +74 -46
- package/dist/api/upload-dir.js +10 -8
- package/dist/esm/index.mjs +110 -73
- package/dist/shared/deploy-site-with-bundle.js +17 -13
- package/dist/shared/wait-for-promises-to-finish.d.ts +1 -0
- package/dist/shared/wait-for-promises-to-finish.js +13 -0
- package/package.json +12 -12
- package/remotionlambda-arm64.zip +0 -0
package/dist/api/deploy-site.js
CHANGED
|
@@ -12,54 +12,82 @@ const full_client_implementation_1 = require("../functions/full-client-implement
|
|
|
12
12
|
const deploy_site_with_bundle_1 = require("../shared/deploy-site-with-bundle");
|
|
13
13
|
const mandatoryDeploySite = async ({ bucketName, entryPoint, siteName, options, region, privacy, gitSource, throwIfSiteExists, providerSpecifics, forcePathStyle, fullClientSpecifics, requestHandler, }) => {
|
|
14
14
|
let generatedBundleDir = null;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
15
|
+
let deploymentOutcome;
|
|
16
|
+
try {
|
|
17
|
+
const result = await (0, deploy_site_with_bundle_1.deploySiteWithBundle)({
|
|
18
|
+
bucketName,
|
|
19
|
+
region,
|
|
20
|
+
siteName,
|
|
21
|
+
options,
|
|
22
|
+
privacy,
|
|
23
|
+
throwIfSiteExists,
|
|
24
|
+
providerSpecifics,
|
|
25
|
+
forcePathStyle,
|
|
26
|
+
fullClientSpecifics,
|
|
27
|
+
requestHandler,
|
|
28
|
+
getBundle: async () => {
|
|
29
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
30
|
+
const bundleDir = await fullClientSpecifics.bundleSite({
|
|
31
|
+
publicPath: `/${(0, constants_1.getSitesKey)(siteName)}/`,
|
|
32
|
+
bundlerOverride: (_a = options.bundlerOverride) !== null && _a !== void 0 ? _a : ((f) => f),
|
|
33
|
+
rspackOverride: (_b = options.rspackOverride) !== null && _b !== void 0 ? _b : ((f) => f),
|
|
34
|
+
webpackOverride: (_c = options.webpackOverride) !== null && _c !== void 0 ? _c : ((f) => f),
|
|
35
|
+
enableCaching: (_d = options.enableCaching) !== null && _d !== void 0 ? _d : true,
|
|
36
|
+
publicDir: (_e = options.publicDir) !== null && _e !== void 0 ? _e : null,
|
|
37
|
+
rootDir: (_f = options.rootDir) !== null && _f !== void 0 ? _f : null,
|
|
38
|
+
ignoreRegisterRootWarning: (_g = options.ignoreRegisterRootWarning) !== null && _g !== void 0 ? _g : false,
|
|
39
|
+
onProgress: (_h = options.onBundleProgress) !== null && _h !== void 0 ? _h : (() => undefined),
|
|
40
|
+
entryPoint,
|
|
41
|
+
gitSource,
|
|
42
|
+
bufferStateDelayInMilliseconds: null,
|
|
43
|
+
maxTimelineTracks: null,
|
|
44
|
+
onDirectoryCreated: (directory) => {
|
|
45
|
+
generatedBundleDir = directory;
|
|
46
|
+
},
|
|
47
|
+
onPublicDirCopyProgress: () => undefined,
|
|
48
|
+
onSymlinkDetected: () => undefined,
|
|
49
|
+
outDir: null,
|
|
50
|
+
askAIEnabled: (_j = options.askAIEnabled) !== null && _j !== void 0 ? _j : true,
|
|
51
|
+
interactivityEnabled: (_k = options.interactivityEnabled) !== null && _k !== void 0 ? _k : true,
|
|
52
|
+
audioLatencyHint: null,
|
|
53
|
+
keyboardShortcutsEnabled: (_l = options.keyboardShortcutsEnabled) !== null && _l !== void 0 ? _l : true,
|
|
54
|
+
renderDefaults: null,
|
|
55
|
+
rspack: (_m = options.rspack) !== null && _m !== void 0 ? _m : false,
|
|
56
|
+
symlinkPublicDir: false,
|
|
57
|
+
});
|
|
58
|
+
generatedBundleDir = bundleDir;
|
|
59
|
+
return bundleDir;
|
|
60
|
+
},
|
|
60
61
|
});
|
|
62
|
+
deploymentOutcome = { type: 'success', result };
|
|
63
|
+
}
|
|
64
|
+
catch (error) {
|
|
65
|
+
deploymentOutcome = { type: 'failure', error };
|
|
66
|
+
}
|
|
67
|
+
let cleanupFailed = false;
|
|
68
|
+
let cleanupError;
|
|
69
|
+
if (generatedBundleDir !== null) {
|
|
70
|
+
try {
|
|
71
|
+
node_fs_1.default.rmSync(generatedBundleDir, {
|
|
72
|
+
force: true,
|
|
73
|
+
recursive: true,
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
catch (error) {
|
|
77
|
+
cleanupFailed = true;
|
|
78
|
+
cleanupError = error;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
if (deploymentOutcome.type === 'failure') {
|
|
82
|
+
if (cleanupFailed) {
|
|
83
|
+
throw new AggregateError([deploymentOutcome.error, cleanupError], 'Deploying the site failed, and removing the generated bundle also failed.', { cause: deploymentOutcome.error });
|
|
84
|
+
}
|
|
85
|
+
throw deploymentOutcome.error;
|
|
86
|
+
}
|
|
87
|
+
if (cleanupFailed) {
|
|
88
|
+
throw cleanupError;
|
|
61
89
|
}
|
|
62
|
-
return result;
|
|
90
|
+
return deploymentOutcome.result;
|
|
63
91
|
};
|
|
64
92
|
exports.internalDeploySite = (0, error_handling_1.wrapWithErrorHandling)(mandatoryDeploySite);
|
|
65
93
|
/*
|
package/dist/api/upload-dir.js
CHANGED
|
@@ -11,6 +11,7 @@ const lambda_client_1 = require("@remotion/lambda-client");
|
|
|
11
11
|
const mime_types_1 = __importDefault(require("mime-types"));
|
|
12
12
|
const make_s3_key_1 = require("../shared/make-s3-key");
|
|
13
13
|
const multipart_upload_part_size_1 = require("../shared/multipart-upload-part-size");
|
|
14
|
+
const wait_for_promises_to_finish_1 = require("../shared/wait-for-promises-to-finish");
|
|
14
15
|
async function getFiles(directory, originalDirectory, toUpload) {
|
|
15
16
|
const dirents = await node_fs_1.promises.readdir(directory, { withFileTypes: true });
|
|
16
17
|
const _files = await Promise.all(dirents
|
|
@@ -96,12 +97,9 @@ const uploadDir = async ({ bucket, region, localDir, onProgress, keyPrefix, priv
|
|
|
96
97
|
throw error;
|
|
97
98
|
}
|
|
98
99
|
};
|
|
99
|
-
const
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
}));
|
|
103
|
-
await Promise.all(uploads);
|
|
104
|
-
})();
|
|
100
|
+
const uploads = files.map((filePath) => limit(async () => {
|
|
101
|
+
await uploadWithRetry(filePath);
|
|
102
|
+
}));
|
|
105
103
|
const interval = setInterval(() => {
|
|
106
104
|
onProgress({
|
|
107
105
|
totalSize: files.map((f) => f.size).reduce((a, b) => a + b, 0),
|
|
@@ -110,7 +108,11 @@ const uploadDir = async ({ bucket, region, localDir, onProgress, keyPrefix, priv
|
|
|
110
108
|
filesUploaded: files.filter((f) => progresses[f.name] === f.size).length,
|
|
111
109
|
});
|
|
112
110
|
}, 1000);
|
|
113
|
-
|
|
114
|
-
|
|
111
|
+
try {
|
|
112
|
+
await (0, wait_for_promises_to_finish_1.waitForPromisesToFinish)(uploads);
|
|
113
|
+
}
|
|
114
|
+
finally {
|
|
115
|
+
clearInterval(interval);
|
|
116
|
+
}
|
|
115
117
|
};
|
|
116
118
|
exports.uploadDir = uploadDir;
|
package/dist/esm/index.mjs
CHANGED
|
@@ -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.
|
|
8607
|
+
version: "4.0.500",
|
|
8608
8608
|
description: "Render Remotion videos on AWS Lambda",
|
|
8609
8609
|
main: "dist/index.js",
|
|
8610
8610
|
scripts: {
|
|
@@ -9691,6 +9691,16 @@ var makeS3Key = (folder, dir, filePath) => {
|
|
|
9691
9691
|
// src/shared/multipart-upload-part-size.ts
|
|
9692
9692
|
var multipartUploadPartSize = 40 * 1024 * 1024;
|
|
9693
9693
|
|
|
9694
|
+
// src/shared/wait-for-promises-to-finish.ts
|
|
9695
|
+
var waitForPromisesToFinish = async (promises) => {
|
|
9696
|
+
try {
|
|
9697
|
+
return await Promise.all(promises);
|
|
9698
|
+
} catch (error) {
|
|
9699
|
+
await Promise.allSettled(promises);
|
|
9700
|
+
throw error;
|
|
9701
|
+
}
|
|
9702
|
+
};
|
|
9703
|
+
|
|
9694
9704
|
// src/api/upload-dir.ts
|
|
9695
9705
|
async function getFiles(directory, originalDirectory, toUpload) {
|
|
9696
9706
|
const dirents = await fs.readdir(directory, { withFileTypes: true });
|
|
@@ -9776,12 +9786,9 @@ var uploadDir = async ({
|
|
|
9776
9786
|
throw error;
|
|
9777
9787
|
}
|
|
9778
9788
|
};
|
|
9779
|
-
const
|
|
9780
|
-
|
|
9781
|
-
|
|
9782
|
-
}));
|
|
9783
|
-
await Promise.all(uploads);
|
|
9784
|
-
})();
|
|
9789
|
+
const uploads = files.map((filePath) => limit(async () => {
|
|
9790
|
+
await uploadWithRetry(filePath);
|
|
9791
|
+
}));
|
|
9785
9792
|
const interval = setInterval(() => {
|
|
9786
9793
|
onProgress({
|
|
9787
9794
|
totalSize: files.map((f) => f.size).reduce((a, b) => a + b, 0),
|
|
@@ -9790,8 +9797,11 @@ var uploadDir = async ({
|
|
|
9790
9797
|
filesUploaded: files.filter((f) => progresses[f.name] === f.size).length
|
|
9791
9798
|
});
|
|
9792
9799
|
}, 1000);
|
|
9793
|
-
|
|
9794
|
-
|
|
9800
|
+
try {
|
|
9801
|
+
await waitForPromisesToFinish(uploads);
|
|
9802
|
+
} finally {
|
|
9803
|
+
clearInterval(interval);
|
|
9804
|
+
}
|
|
9795
9805
|
};
|
|
9796
9806
|
|
|
9797
9807
|
// src/shared/read-dir.ts
|
|
@@ -10154,16 +10164,18 @@ var deploySiteWithBundle = async ({
|
|
|
10154
10164
|
throw new Error(`No bucket with the name ${bucketName} exists`);
|
|
10155
10165
|
}
|
|
10156
10166
|
const subFolder = getSitesKey2(siteName);
|
|
10157
|
-
const
|
|
10158
|
-
|
|
10159
|
-
|
|
10160
|
-
|
|
10161
|
-
|
|
10162
|
-
|
|
10163
|
-
|
|
10164
|
-
|
|
10165
|
-
|
|
10166
|
-
|
|
10167
|
+
const filesPromise = providerSpecifics.listObjects({
|
|
10168
|
+
bucketName,
|
|
10169
|
+
expectedBucketOwner: accountId,
|
|
10170
|
+
region,
|
|
10171
|
+
prefix: `${subFolder}/`,
|
|
10172
|
+
forcePathStyle,
|
|
10173
|
+
requestHandler
|
|
10174
|
+
});
|
|
10175
|
+
const bundlePromise = getBundle();
|
|
10176
|
+
const [files, bundleDir] = await waitForPromisesToFinish([
|
|
10177
|
+
filesPromise,
|
|
10178
|
+
bundlePromise
|
|
10167
10179
|
]);
|
|
10168
10180
|
if (throwIfSiteExists && files.length > 0) {
|
|
10169
10181
|
throw new Error("`throwIfSiteExists` was passed as true, but there are already files in this folder: " + files.slice(0, 5).map((f) => f.Key).join(", "));
|
|
@@ -10205,7 +10217,7 @@ var deploySiteWithBundle = async ({
|
|
|
10205
10217
|
await upload(assetsToUpload);
|
|
10206
10218
|
await upload(indexHtmlToUpload);
|
|
10207
10219
|
const limit2 = LambdaClientInternals6.pLimit(deleteConcurrency);
|
|
10208
|
-
|
|
10220
|
+
const deletePromises = toDelete.map((d) => {
|
|
10209
10221
|
return limit2(() => {
|
|
10210
10222
|
return providerSpecifics.deleteFile({
|
|
10211
10223
|
bucketName,
|
|
@@ -10216,7 +10228,8 @@ var deploySiteWithBundle = async ({
|
|
|
10216
10228
|
requestHandler
|
|
10217
10229
|
});
|
|
10218
10230
|
});
|
|
10219
|
-
})
|
|
10231
|
+
});
|
|
10232
|
+
await waitForPromisesToFinish(deletePromises);
|
|
10220
10233
|
return {
|
|
10221
10234
|
serveUrl: LambdaClientInternals6.makeS3ServeUrl({
|
|
10222
10235
|
bucketName,
|
|
@@ -10248,61 +10261,85 @@ var mandatoryDeploySite = async ({
|
|
|
10248
10261
|
requestHandler
|
|
10249
10262
|
}) => {
|
|
10250
10263
|
let generatedBundleDir = null;
|
|
10251
|
-
|
|
10252
|
-
|
|
10253
|
-
|
|
10254
|
-
|
|
10255
|
-
|
|
10256
|
-
|
|
10257
|
-
|
|
10258
|
-
|
|
10259
|
-
|
|
10260
|
-
|
|
10261
|
-
|
|
10262
|
-
|
|
10263
|
-
|
|
10264
|
-
|
|
10265
|
-
|
|
10266
|
-
|
|
10267
|
-
|
|
10268
|
-
|
|
10269
|
-
|
|
10270
|
-
|
|
10271
|
-
|
|
10272
|
-
|
|
10273
|
-
|
|
10274
|
-
|
|
10275
|
-
|
|
10276
|
-
|
|
10277
|
-
|
|
10278
|
-
|
|
10279
|
-
|
|
10280
|
-
|
|
10281
|
-
|
|
10282
|
-
|
|
10283
|
-
|
|
10284
|
-
|
|
10285
|
-
|
|
10286
|
-
|
|
10287
|
-
|
|
10288
|
-
|
|
10289
|
-
|
|
10290
|
-
|
|
10291
|
-
|
|
10292
|
-
|
|
10293
|
-
|
|
10294
|
-
|
|
10295
|
-
|
|
10264
|
+
let deploymentOutcome;
|
|
10265
|
+
try {
|
|
10266
|
+
const result = await deploySiteWithBundle({
|
|
10267
|
+
bucketName,
|
|
10268
|
+
region,
|
|
10269
|
+
siteName,
|
|
10270
|
+
options,
|
|
10271
|
+
privacy,
|
|
10272
|
+
throwIfSiteExists,
|
|
10273
|
+
providerSpecifics,
|
|
10274
|
+
forcePathStyle,
|
|
10275
|
+
fullClientSpecifics,
|
|
10276
|
+
requestHandler,
|
|
10277
|
+
getBundle: async () => {
|
|
10278
|
+
const bundleDir = await fullClientSpecifics.bundleSite({
|
|
10279
|
+
publicPath: `/${getSitesKey3(siteName)}/`,
|
|
10280
|
+
bundlerOverride: options.bundlerOverride ?? ((f) => f),
|
|
10281
|
+
rspackOverride: options.rspackOverride ?? ((f) => f),
|
|
10282
|
+
webpackOverride: options.webpackOverride ?? ((f) => f),
|
|
10283
|
+
enableCaching: options.enableCaching ?? true,
|
|
10284
|
+
publicDir: options.publicDir ?? null,
|
|
10285
|
+
rootDir: options.rootDir ?? null,
|
|
10286
|
+
ignoreRegisterRootWarning: options.ignoreRegisterRootWarning ?? false,
|
|
10287
|
+
onProgress: options.onBundleProgress ?? (() => {
|
|
10288
|
+
return;
|
|
10289
|
+
}),
|
|
10290
|
+
entryPoint,
|
|
10291
|
+
gitSource,
|
|
10292
|
+
bufferStateDelayInMilliseconds: null,
|
|
10293
|
+
maxTimelineTracks: null,
|
|
10294
|
+
onDirectoryCreated: (directory) => {
|
|
10295
|
+
generatedBundleDir = directory;
|
|
10296
|
+
},
|
|
10297
|
+
onPublicDirCopyProgress: () => {
|
|
10298
|
+
return;
|
|
10299
|
+
},
|
|
10300
|
+
onSymlinkDetected: () => {
|
|
10301
|
+
return;
|
|
10302
|
+
},
|
|
10303
|
+
outDir: null,
|
|
10304
|
+
askAIEnabled: options.askAIEnabled ?? true,
|
|
10305
|
+
interactivityEnabled: options.interactivityEnabled ?? true,
|
|
10306
|
+
audioLatencyHint: null,
|
|
10307
|
+
keyboardShortcutsEnabled: options.keyboardShortcutsEnabled ?? true,
|
|
10308
|
+
renderDefaults: null,
|
|
10309
|
+
rspack: options.rspack ?? false,
|
|
10310
|
+
symlinkPublicDir: false
|
|
10311
|
+
});
|
|
10312
|
+
generatedBundleDir = bundleDir;
|
|
10313
|
+
return bundleDir;
|
|
10314
|
+
}
|
|
10315
|
+
});
|
|
10316
|
+
deploymentOutcome = { type: "success", result };
|
|
10317
|
+
} catch (error) {
|
|
10318
|
+
deploymentOutcome = { type: "failure", error };
|
|
10319
|
+
}
|
|
10320
|
+
let cleanupFailed = false;
|
|
10321
|
+
let cleanupError;
|
|
10322
|
+
if (generatedBundleDir !== null) {
|
|
10323
|
+
try {
|
|
10324
|
+
fs4.rmSync(generatedBundleDir, {
|
|
10325
|
+
force: true,
|
|
10326
|
+
recursive: true
|
|
10296
10327
|
});
|
|
10297
|
-
|
|
10328
|
+
} catch (error) {
|
|
10329
|
+
cleanupFailed = true;
|
|
10330
|
+
cleanupError = error;
|
|
10298
10331
|
}
|
|
10299
|
-
});
|
|
10300
|
-
if (generatedBundleDir && fs4.existsSync(generatedBundleDir)) {
|
|
10301
|
-
fs4.rmSync(generatedBundleDir, {
|
|
10302
|
-
recursive: true
|
|
10303
|
-
});
|
|
10304
10332
|
}
|
|
10305
|
-
|
|
10333
|
+
if (deploymentOutcome.type === "failure") {
|
|
10334
|
+
if (cleanupFailed) {
|
|
10335
|
+
throw new AggregateError([deploymentOutcome.error, cleanupError], "Deploying the site failed, and removing the generated bundle also failed.", { cause: deploymentOutcome.error });
|
|
10336
|
+
}
|
|
10337
|
+
throw deploymentOutcome.error;
|
|
10338
|
+
}
|
|
10339
|
+
if (cleanupFailed) {
|
|
10340
|
+
throw cleanupError;
|
|
10341
|
+
}
|
|
10342
|
+
return deploymentOutcome.result;
|
|
10306
10343
|
};
|
|
10307
10344
|
var internalDeploySite = wrapWithErrorHandling2(mandatoryDeploySite);
|
|
10308
10345
|
var deploySite = (args) => {
|
|
@@ -6,6 +6,7 @@ const constants_1 = require("@remotion/lambda-client/constants");
|
|
|
6
6
|
const serverless_1 = require("@remotion/serverless");
|
|
7
7
|
const get_s3_operations_1 = require("./get-s3-operations");
|
|
8
8
|
const validate_site_name_1 = require("./validate-site-name");
|
|
9
|
+
const wait_for_promises_to_finish_1 = require("./wait-for-promises-to-finish");
|
|
9
10
|
const deleteConcurrency = 10;
|
|
10
11
|
const deploySiteWithBundle = async ({ bucketName, region, siteName, options, privacy, throwIfSiteExists, providerSpecifics, forcePathStyle, fullClientSpecifics, requestHandler, getBundle, }) => {
|
|
11
12
|
var _a, _b;
|
|
@@ -31,17 +32,19 @@ const deploySiteWithBundle = async ({ bucketName, region, siteName, options, pri
|
|
|
31
32
|
throw new Error(`No bucket with the name ${bucketName} exists`);
|
|
32
33
|
}
|
|
33
34
|
const subFolder = (0, constants_1.getSitesKey)(siteName);
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
35
|
+
const filesPromise = providerSpecifics.listObjects({
|
|
36
|
+
bucketName,
|
|
37
|
+
expectedBucketOwner: accountId,
|
|
38
|
+
region,
|
|
39
|
+
// The `/` is important to not accidentally delete sites with the same name but containing a suffix.
|
|
40
|
+
prefix: `${subFolder}/`,
|
|
41
|
+
forcePathStyle,
|
|
42
|
+
requestHandler,
|
|
43
|
+
});
|
|
44
|
+
const bundlePromise = getBundle();
|
|
45
|
+
const [files, bundleDir] = await (0, wait_for_promises_to_finish_1.waitForPromisesToFinish)([
|
|
46
|
+
filesPromise,
|
|
47
|
+
bundlePromise,
|
|
45
48
|
]);
|
|
46
49
|
if (throwIfSiteExists && files.length > 0) {
|
|
47
50
|
throw new Error('`throwIfSiteExists` was passed as true, but there are already files in this folder: ' +
|
|
@@ -87,7 +90,7 @@ const deploySiteWithBundle = async ({ bucketName, region, siteName, options, pri
|
|
|
87
90
|
await upload(assetsToUpload);
|
|
88
91
|
await upload(indexHtmlToUpload);
|
|
89
92
|
const limit = lambda_client_1.LambdaClientInternals.pLimit(deleteConcurrency);
|
|
90
|
-
|
|
93
|
+
const deletePromises = toDelete.map((d) => {
|
|
91
94
|
return limit(() => {
|
|
92
95
|
return providerSpecifics.deleteFile({
|
|
93
96
|
bucketName,
|
|
@@ -98,7 +101,8 @@ const deploySiteWithBundle = async ({ bucketName, region, siteName, options, pri
|
|
|
98
101
|
requestHandler,
|
|
99
102
|
});
|
|
100
103
|
});
|
|
101
|
-
})
|
|
104
|
+
});
|
|
105
|
+
await (0, wait_for_promises_to_finish_1.waitForPromisesToFinish)(deletePromises);
|
|
102
106
|
return {
|
|
103
107
|
serveUrl: lambda_client_1.LambdaClientInternals.makeS3ServeUrl({
|
|
104
108
|
bucketName,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const waitForPromisesToFinish: <T extends readonly PromiseLike<unknown>[]>(promises: T) => Promise<{ -readonly [P in keyof T]: Awaited<T[P]>; }>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.waitForPromisesToFinish = void 0;
|
|
4
|
+
const waitForPromisesToFinish = async (promises) => {
|
|
5
|
+
try {
|
|
6
|
+
return await Promise.all(promises);
|
|
7
|
+
}
|
|
8
|
+
catch (error) {
|
|
9
|
+
await Promise.allSettled(promises);
|
|
10
|
+
throw error;
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
exports.waitForPromisesToFinish = waitForPromisesToFinish;
|
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.
|
|
6
|
+
"version": "4.0.500",
|
|
7
7
|
"description": "Render Remotion videos on AWS Lambda",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"scripts": {
|
|
@@ -28,22 +28,22 @@
|
|
|
28
28
|
"@aws-sdk/client-cloudwatch-logs": "3.986.0",
|
|
29
29
|
"@aws-sdk/client-service-quotas": "3.986.0",
|
|
30
30
|
"@aws-sdk/lib-storage": "3.986.0",
|
|
31
|
-
"@remotion/bundler": "4.0.
|
|
32
|
-
"@remotion/cli": "4.0.
|
|
33
|
-
"@remotion/lambda-client": "4.0.
|
|
34
|
-
"@remotion/renderer": "4.0.
|
|
35
|
-
"@remotion/serverless": "4.0.
|
|
36
|
-
"@remotion/streaming": "4.0.
|
|
31
|
+
"@remotion/bundler": "4.0.500",
|
|
32
|
+
"@remotion/cli": "4.0.500",
|
|
33
|
+
"@remotion/lambda-client": "4.0.500",
|
|
34
|
+
"@remotion/renderer": "4.0.500",
|
|
35
|
+
"@remotion/serverless": "4.0.500",
|
|
36
|
+
"@remotion/streaming": "4.0.500",
|
|
37
37
|
"@smithy/abort-controller": "4.0.1",
|
|
38
|
-
"remotion": "4.0.
|
|
38
|
+
"remotion": "4.0.500",
|
|
39
39
|
"zod": "4.4.3"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@remotion/bundler": "4.0.
|
|
42
|
+
"@remotion/bundler": "4.0.500",
|
|
43
43
|
"@types/express": "5.0.1",
|
|
44
44
|
"express": "4.21.0",
|
|
45
|
-
"@remotion/compositor-linux-arm64-gnu": "4.0.
|
|
46
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
45
|
+
"@remotion/compositor-linux-arm64-gnu": "4.0.500",
|
|
46
|
+
"@remotion/eslint-config-internal": "4.0.500",
|
|
47
47
|
"mime-types": "2.1.34",
|
|
48
48
|
"@types/mime-types": "2.1.1",
|
|
49
49
|
"@types/minimist": "1.2.2",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"@typescript/native-preview": "7.0.0-dev.20260217.1"
|
|
55
55
|
},
|
|
56
56
|
"peerDependencies": {
|
|
57
|
-
"@remotion/bundler": "4.0.
|
|
57
|
+
"@remotion/bundler": "4.0.500"
|
|
58
58
|
},
|
|
59
59
|
"publishConfig": {
|
|
60
60
|
"access": "public"
|
package/remotionlambda-arm64.zip
CHANGED
|
Binary file
|