UNPKG

cdk-nextjs-standalone

Version:

Deploy a NextJS app to AWS using CDK and OpenNext.

66 lines (65 loc) 1.86 kB
import type { NextjsBuild, NextjsDistributionDefaults, NextjsDistributionOverrides, NextjsDomain } from '../'; import type { aws_cloudfront, aws_lambda, aws_s3 } from 'aws-cdk-lib'; /** * OptionalNextjsDistributionProps */ export interface OptionalNextjsDistributionProps { /** * Supress the creation of default policies if none are provided by you. * @stability stable */ readonly supressDefaults?: NextjsDistributionDefaults; /** * @stability stable */ readonly streaming?: boolean; /** * Override props for every construct. * @stability stable */ readonly overrides?: NextjsDistributionOverrides; /** * @stability stable */ readonly nextDomain?: NextjsDomain; /** * Override lambda function url auth type. * @default "NONE" * @stability stable */ readonly functionUrlAuthType?: aws_lambda.FunctionUrlAuthType; /** * @stability stable */ readonly distribution?: aws_cloudfront.Distribution; /** * @stability stable */ readonly basePath?: string; /** * Bucket containing static assets. * Must be provided if you want to serve static files. * @stability stable */ readonly staticAssetsBucket?: aws_s3.IBucket; /** * Lambda function to route all non-static requests to. * Must be provided if you want to serve dynamic requests. * @stability stable */ readonly serverFunction?: aws_lambda.IFunction; /** * @stability stable */ readonly nextjsPath?: string; /** * @stability stable */ readonly nextBuild?: NextjsBuild; /** * Lambda function to optimize images. * Must be provided if you want to serve dynamic requests. * @stability stable */ readonly imageOptFunction?: aws_lambda.IFunction; }