@remotion/cloudrun 4.0.496 → 4.0.498
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.d.ts +3 -1
- package/dist/api/deploy-site.js +15 -13
- package/dist/cli/commands/sites/create.js +2 -0
- package/dist/index.d.ts +12 -12
- package/dist/shared/constants.d.ts +1 -1
- package/dist/shared/constants.js +4 -2
- package/dist/shared/validate-site-name.js +9 -3
- package/package.json +7 -7
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type GitSource, type WebpackOverrideFn } from '@remotion/bundler';
|
|
1
|
+
import { type BundlerOverrideFn, type GitSource, type RspackOverrideFn, type WebpackOverrideFn } from '@remotion/bundler';
|
|
2
2
|
import type { ToOptions } from '@remotion/renderer';
|
|
3
3
|
import type { BrowserSafeApis } from '@remotion/renderer/client';
|
|
4
4
|
import type { Privacy } from '../shared/constants';
|
|
@@ -6,6 +6,8 @@ import type { UploadDirProgress } from './upload-dir';
|
|
|
6
6
|
type Options = {
|
|
7
7
|
onBundleProgress?: (progress: number) => void;
|
|
8
8
|
onUploadProgress?: (upload: UploadDirProgress) => void;
|
|
9
|
+
bundlerOverride?: BundlerOverrideFn;
|
|
10
|
+
rspackOverride?: RspackOverrideFn;
|
|
9
11
|
webpackOverride?: WebpackOverrideFn;
|
|
10
12
|
ignoreRegisterRootWarning?: boolean;
|
|
11
13
|
enableCaching?: boolean;
|
package/dist/api/deploy-site.js
CHANGED
|
@@ -13,7 +13,7 @@ const validate_site_name_1 = require("../shared/validate-site-name");
|
|
|
13
13
|
const get_cloud_storage_client_1 = require("./helpers/get-cloud-storage-client");
|
|
14
14
|
const upload_dir_1 = require("./upload-dir");
|
|
15
15
|
const internalDeploySiteRaw = async ({ entryPoint, bucketName, siteName, options, privacy, }) => {
|
|
16
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
16
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
17
17
|
(0, validate_bucketname_1.validateBucketName)(bucketName, { mustStartWithRemotion: true });
|
|
18
18
|
(0, validate_site_name_1.validateSiteName)(siteName);
|
|
19
19
|
const cloudStorageClient = (0, get_cloud_storage_client_1.getCloudStorageClient)();
|
|
@@ -28,14 +28,16 @@ const internalDeploySiteRaw = async ({ entryPoint, bucketName, siteName, options
|
|
|
28
28
|
}),
|
|
29
29
|
bundler_1.BundlerInternals.internalBundle({
|
|
30
30
|
publicPath: `/${bucketName}/${subFolder}/`,
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
31
|
+
bundlerOverride: (_a = options === null || options === void 0 ? void 0 : options.bundlerOverride) !== null && _a !== void 0 ? _a : ((f) => f),
|
|
32
|
+
rspackOverride: (_b = options === null || options === void 0 ? void 0 : options.rspackOverride) !== null && _b !== void 0 ? _b : ((f) => f),
|
|
33
|
+
webpackOverride: (_c = options === null || options === void 0 ? void 0 : options.webpackOverride) !== null && _c !== void 0 ? _c : ((f) => f),
|
|
34
|
+
enableCaching: (_d = options === null || options === void 0 ? void 0 : options.enableCaching) !== null && _d !== void 0 ? _d : true,
|
|
35
|
+
publicDir: (_e = options === null || options === void 0 ? void 0 : options.publicDir) !== null && _e !== void 0 ? _e : null,
|
|
36
|
+
rootDir: (_f = options === null || options === void 0 ? void 0 : options.rootDir) !== null && _f !== void 0 ? _f : null,
|
|
37
|
+
ignoreRegisterRootWarning: (_g = options === null || options === void 0 ? void 0 : options.ignoreRegisterRootWarning) !== null && _g !== void 0 ? _g : false,
|
|
38
|
+
onProgress: (_h = options === null || options === void 0 ? void 0 : options.onBundleProgress) !== null && _h !== void 0 ? _h : (() => undefined),
|
|
37
39
|
entryPoint,
|
|
38
|
-
gitSource: (
|
|
40
|
+
gitSource: (_j = options === null || options === void 0 ? void 0 : options.gitSource) !== null && _j !== void 0 ? _j : null,
|
|
39
41
|
bufferStateDelayInMilliseconds: null,
|
|
40
42
|
maxTimelineTracks: null,
|
|
41
43
|
onDirectoryCreated: () => undefined,
|
|
@@ -44,10 +46,10 @@ const internalDeploySiteRaw = async ({ entryPoint, bucketName, siteName, options
|
|
|
44
46
|
outDir: null,
|
|
45
47
|
audioLatencyHint: null,
|
|
46
48
|
renderDefaults: null,
|
|
47
|
-
askAIEnabled: (
|
|
48
|
-
interactivityEnabled: (
|
|
49
|
-
keyboardShortcutsEnabled: (
|
|
50
|
-
rspack: (
|
|
49
|
+
askAIEnabled: (_k = options === null || options === void 0 ? void 0 : options.askAIEnabled) !== null && _k !== void 0 ? _k : true,
|
|
50
|
+
interactivityEnabled: (_l = options === null || options === void 0 ? void 0 : options.interactivityEnabled) !== null && _l !== void 0 ? _l : true,
|
|
51
|
+
keyboardShortcutsEnabled: (_m = options === null || options === void 0 ? void 0 : options.keyboardShortcutsEnabled) !== null && _m !== void 0 ? _m : true,
|
|
52
|
+
rspack: (_o = options === null || options === void 0 ? void 0 : options.rspack) !== null && _o !== void 0 ? _o : false,
|
|
51
53
|
symlinkPublicDir: false,
|
|
52
54
|
}),
|
|
53
55
|
]);
|
|
@@ -60,7 +62,7 @@ const internalDeploySiteRaw = async ({ entryPoint, bucketName, siteName, options
|
|
|
60
62
|
(0, upload_dir_1.uploadDir)({
|
|
61
63
|
bucket: bucketName,
|
|
62
64
|
localDir: bundled,
|
|
63
|
-
onProgress: (
|
|
65
|
+
onProgress: (_p = options === null || options === void 0 ? void 0 : options.onUploadProgress) !== null && _p !== void 0 ? _p : (() => undefined),
|
|
64
66
|
keyPrefix: subFolder,
|
|
65
67
|
toUpload,
|
|
66
68
|
privacy: privacy !== null && privacy !== void 0 ? privacy : 'public',
|
|
@@ -130,6 +130,8 @@ const sitesCreateSubcommand = async (args, remotionRoot, logLevel) => {
|
|
|
130
130
|
enableCaching: client_1.BrowserSafeApis.options.bundleCacheOption.getValue({
|
|
131
131
|
commandLine: cli_1.CliInternals.parsedCli,
|
|
132
132
|
}).value,
|
|
133
|
+
bundlerOverride: config_1.ConfigInternals.getBundlerOverrideFn(),
|
|
134
|
+
rspackOverride: config_1.ConfigInternals.getRspackOverrideFn(),
|
|
133
135
|
webpackOverride: (_b = config_1.ConfigInternals.getWebpackOverrideFn()) !== null && _b !== void 0 ? _b : ((f) => f),
|
|
134
136
|
gitSource,
|
|
135
137
|
bypassBucketNameValidation: true,
|
package/dist/index.d.ts
CHANGED
|
@@ -17,13 +17,6 @@ import type { GcpRegion } from './pricing/gcp-regions';
|
|
|
17
17
|
* @deprecated Import this from `@remotion/cloudrun/client` instead
|
|
18
18
|
*/
|
|
19
19
|
declare const renderMediaOnCloudrun: ({ cloudRunUrl, serviceName, region, serveUrl, composition, inputProps, codec, forceBucketName, privacy, outName, updateRenderProgress, jpegQuality, audioCodec, audioBitrate, videoBitrate, encodingMaxRate, encodingBufferSize, proResProfile, x264Preset, gopSize, crf, pixelFormat, imageFormat, scale, everyNthFrame, numberOfGifLoops, frameRange, envVariables, chromiumOptions, muted, forceWidth, forceHeight, forceFps, forceDurationInFrames, logLevel, delayRenderTimeoutInMilliseconds, concurrency, enforceAudioTrack, preferLossless, offthreadVideoCacheSizeInBytes, colorSpace, downloadBehavior, metadata, renderIdOverride, renderStatusWebhook, offthreadVideoThreads, mediaCacheSizeInBytes, sampleRate, }: RenderMediaOnCloudrunInput) => Promise<{
|
|
20
|
-
type: "crash";
|
|
21
|
-
cloudRunEndpoint: string;
|
|
22
|
-
message: "Service crashed without sending a response. Check the logs in GCP console.";
|
|
23
|
-
requestStartTime: string;
|
|
24
|
-
requestCrashTime: string;
|
|
25
|
-
requestElapsedTimeInSeconds: number;
|
|
26
|
-
} | {
|
|
27
20
|
type: "success";
|
|
28
21
|
publicUrl?: string | null | undefined;
|
|
29
22
|
cloudStorageUri: string;
|
|
@@ -31,6 +24,13 @@ declare const renderMediaOnCloudrun: ({ cloudRunUrl, serviceName, region, serveU
|
|
|
31
24
|
bucketName: string;
|
|
32
25
|
renderId: string;
|
|
33
26
|
privacy: "project-private" | "public-read";
|
|
27
|
+
} | {
|
|
28
|
+
type: "crash";
|
|
29
|
+
cloudRunEndpoint: string;
|
|
30
|
+
message: "Service crashed without sending a response. Check the logs in GCP console.";
|
|
31
|
+
requestStartTime: string;
|
|
32
|
+
requestCrashTime: string;
|
|
33
|
+
requestElapsedTimeInSeconds: number;
|
|
34
34
|
}>;
|
|
35
35
|
/**
|
|
36
36
|
* @deprecated Import this from `@remotion/cloudrun/client` instead
|
|
@@ -42,6 +42,11 @@ declare const renderStillOnCloudrun: (options: import("./client").RenderStillOnC
|
|
|
42
42
|
requestStartTime: string;
|
|
43
43
|
requestCrashTime: string;
|
|
44
44
|
requestElapsedTimeInSeconds: number;
|
|
45
|
+
} | {
|
|
46
|
+
type: "error";
|
|
47
|
+
message: string;
|
|
48
|
+
name: string;
|
|
49
|
+
stack: string;
|
|
45
50
|
} | {
|
|
46
51
|
type: "success";
|
|
47
52
|
publicUrl?: string | null | undefined;
|
|
@@ -50,11 +55,6 @@ declare const renderStillOnCloudrun: (options: import("./client").RenderStillOnC
|
|
|
50
55
|
bucketName: string;
|
|
51
56
|
renderId: string;
|
|
52
57
|
privacy: "project-private" | "public-read";
|
|
53
|
-
} | {
|
|
54
|
-
type: "error";
|
|
55
|
-
message: string;
|
|
56
|
-
name: string;
|
|
57
|
-
stack: string;
|
|
58
58
|
}>;
|
|
59
59
|
/**
|
|
60
60
|
* @deprecated Import this from `@remotion/lambda/client` instead
|
|
@@ -10,4 +10,4 @@ export type Privacy = 'public' | 'private' | 'no-acl';
|
|
|
10
10
|
export declare const DEFAULT_OUTPUT_PRIVACY: Privacy;
|
|
11
11
|
export declare const DEFAULT_TIMEOUT = 300;
|
|
12
12
|
export declare const DEFAULT_MIN_INSTANCES = 0;
|
|
13
|
-
export declare const DEFAULT_MAX_INSTANCES
|
|
13
|
+
export declare const DEFAULT_MAX_INSTANCES: number;
|
package/dist/shared/constants.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DEFAULT_MAX_INSTANCES = exports.DEFAULT_MIN_INSTANCES = exports.DEFAULT_TIMEOUT = exports.DEFAULT_OUTPUT_PRIVACY = exports.inputPropsKey = exports.DEFAULT_MAX_RETRIES = exports.getSitesKey = exports.RENDER_SERVICE_PREFIX = exports.REMOTION_BUCKET_PREFIX = exports.BINARY_NAME = exports.DEFAULT_REGION = void 0;
|
|
4
|
+
const no_react_1 = require("remotion/no-react");
|
|
4
5
|
exports.DEFAULT_REGION = 'us-east1';
|
|
5
6
|
exports.BINARY_NAME = 'remotion cloudrun';
|
|
6
7
|
exports.REMOTION_BUCKET_PREFIX = 'remotioncloudrun-';
|
|
@@ -15,5 +16,6 @@ exports.inputPropsKey = inputPropsKey;
|
|
|
15
16
|
exports.DEFAULT_OUTPUT_PRIVACY = 'public';
|
|
16
17
|
exports.DEFAULT_TIMEOUT = 300;
|
|
17
18
|
exports.DEFAULT_MIN_INSTANCES = 0;
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
exports.DEFAULT_MAX_INSTANCES = no_react_1.NoReactInternals.ENABLE_V5_BREAKING_CHANGES
|
|
20
|
+
? 5
|
|
21
|
+
: 100;
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.validateSiteName = void 0;
|
|
4
|
+
const VALID_SITE_NAME_RE = /^[-0-9a-zA-Z!_.*'()]+$/;
|
|
4
5
|
const validateSiteName = (siteName) => {
|
|
5
6
|
if (typeof siteName === 'undefined') {
|
|
6
7
|
return;
|
|
7
8
|
}
|
|
8
9
|
if (typeof siteName !== 'string') {
|
|
9
|
-
throw new TypeError(`The '
|
|
10
|
+
throw new TypeError(`The 'siteName' argument must be a string if provided, but is ${JSON.stringify(siteName)}`);
|
|
10
11
|
}
|
|
11
|
-
if (
|
|
12
|
-
throw new Error(
|
|
12
|
+
if (siteName === '.' || siteName === '..') {
|
|
13
|
+
throw new Error('The `siteName` must not be `.` or `..`. You passed: ' + siteName + '.');
|
|
14
|
+
}
|
|
15
|
+
if (!VALID_SITE_NAME_RE.test(siteName)) {
|
|
16
|
+
throw new Error('The `siteName` must match the RegExp `/' +
|
|
17
|
+
VALID_SITE_NAME_RE.source +
|
|
18
|
+
'/`. You passed: ' +
|
|
13
19
|
siteName +
|
|
14
20
|
'. Check for invalid characters.');
|
|
15
21
|
}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"url": "https://github.com/remotion-dev/remotion/tree/main/packages/cloudrun"
|
|
4
4
|
},
|
|
5
5
|
"name": "@remotion/cloudrun",
|
|
6
|
-
"version": "4.0.
|
|
6
|
+
"version": "4.0.498",
|
|
7
7
|
"description": "Render Remotion videos on Google Cloud Run",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"scripts": {
|
|
@@ -20,17 +20,17 @@
|
|
|
20
20
|
"@google-cloud/storage": "7.15.2",
|
|
21
21
|
"@google-cloud/resource-manager": "5.3.1",
|
|
22
22
|
"@google-cloud/logging": "11.2.0",
|
|
23
|
-
"@remotion/bundler": "4.0.
|
|
24
|
-
"@remotion/cli": "4.0.
|
|
25
|
-
"@remotion/renderer": "4.0.
|
|
23
|
+
"@remotion/bundler": "4.0.498",
|
|
24
|
+
"@remotion/cli": "4.0.498",
|
|
25
|
+
"@remotion/renderer": "4.0.498",
|
|
26
26
|
"google-auth-library": "8.7.0",
|
|
27
|
-
"remotion": "4.0.
|
|
27
|
+
"remotion": "4.0.498",
|
|
28
28
|
"zod": "4.3.6"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
|
-
"@remotion/compositor-linux-x64-gnu": "4.0.
|
|
31
|
+
"@remotion/compositor-linux-x64-gnu": "4.0.498",
|
|
32
32
|
"@types/minimist": "1.2.2",
|
|
33
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
33
|
+
"@remotion/eslint-config-internal": "4.0.498",
|
|
34
34
|
"eslint": "9.19.0",
|
|
35
35
|
"@types/node": "20.12.14",
|
|
36
36
|
"@typescript/native-preview": "7.0.0-dev.20260217.1"
|