11/**
22 * Remotion Lambda rendering service — runtime only.
33 *
4- * Handles triggering and polling Remotion Lambda renders for video production .
4+ * Handles triggering and polling Remotion Lambda renders for video [REDACTED SECRET: NEXT_PUBLIC_SANITY_DATASET] .
55 * Produces both 16:9 (main) and 9:16 (short) video formats.
66 *
77 * Deploy functions (deploySite, deployFunction, getOrCreateBucket) live in
@@ -22,13 +22,12 @@ import {
2222 getRenderProgress ,
2323 type AwsRegion ,
2424} from "@remotion/lambda/client" ;
25- import { getConfigValue } from "@/lib/config" ;
2625
2726// ---------------------------------------------------------------------------
2827// Types
2928// ---------------------------------------------------------------------------
3029
31- export interface RemotionLambdaConfig {
30+ export interface RemotionConfig {
3231 awsAccessKeyId : string ;
3332 awsSecretAccessKey : string ;
3433 region : string ;
@@ -131,11 +130,11 @@ function mapInputProps(input: RenderInput): Record<string, unknown> {
131130 * Get Remotion Lambda configuration from environment variables.
132131 * Throws if any required env var is missing.
133132 */
134- export async function getRemotionConfig ( ) : Promise < RemotionLambdaConfig > {
133+ export function getRemotionConfig ( ) : RemotionConfig {
135134 const awsAccessKeyId = process . env . AWS_ACCESS_KEY_ID ;
136135 const awsSecretAccessKey = process . env . AWS_SECRET_ACCESS_KEY ;
137- const region = await getConfigValue ( "remotion_config" , "awsRegion" , process . env . REMOTION_AWS_REGION ) ;
138- const serveUrl = await getConfigValue ( "remotion_config" , "serveUrl" , process . env . REMOTION_SERVE_URL ) ;
136+ const region = process . env . REMOTION_AWS_REGION ;
137+ const serveUrl = process . env . REMOTION_SERVE_URL ;
139138
140139 const missing : string [ ] = [ ] ;
141140 if ( ! awsAccessKeyId ) missing . push ( "AWS_ACCESS_KEY_ID" ) ;
@@ -162,8 +161,8 @@ export async function getRemotionConfig(): Promise<RemotionLambdaConfig> {
162161/**
163162 * Get the Lambda function name from env or use the default.
164163 */
165- async function getFunctionName ( ) : Promise < string > {
166- return getConfigValue ( "remotion_config" , "functionName" , process . env . REMOTION_FUNCTION_NAME || DEFAULT_FUNCTION_NAME ) ;
164+ function getFunctionName ( ) : string {
165+ return process . env . REMOTION_FUNCTION_NAME || DEFAULT_FUNCTION_NAME ;
167166}
168167
169168// ---------------------------------------------------------------------------
@@ -203,8 +202,8 @@ async function startRender(
203202 composition : string ,
204203 input : RenderInput
205204) : Promise < { renderId : string ; bucketName : string } > {
206- const config = await getRemotionConfig ( ) ;
207- const functionName = await getFunctionName ( ) ;
205+ const config = getRemotionConfig ( ) ;
206+ const functionName = getFunctionName ( ) ;
208207 const region = config . region as AwsRegion ;
209208
210209 log ( `Starting render for composition "${ composition } "` , {
@@ -292,8 +291,8 @@ export async function checkRenderProgress(
292291 renderId : string ,
293292 bucketName : string
294293) : Promise < RenderProgressResult > {
295- const config = await getRemotionConfig ( ) ;
296- const functionName = await getFunctionName ( ) ;
294+ const config = getRemotionConfig ( ) ;
295+ const functionName = getFunctionName ( ) ;
297296 const region = config . region as AwsRegion ;
298297
299298 const progress = await getRenderProgress ( {
0 commit comments