Skip to content
v2.275.0

CodeConfigurationProperty Struct ​

Describes the configuration that AWS App Runner uses to build and run an App Runner service from a source code repository.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_apprunner as apprunner } from 'aws-cdk-lib';
const codeConfigurationProperty: apprunner.CfnService.CodeConfigurationProperty = {
  configurationSource: 'configurationSource',

  // the properties below are optional
  codeConfigurationValues: {
    runtime: 'runtime',

    // the properties below are optional
    buildCommand: 'buildCommand',
    port: 'port',
    runtimeEnvironmentSecrets: [{
      name: 'name',
      value: 'value',
    }],
    runtimeEnvironmentVariables: [{
      name: 'name',
      value: 'value',
    }],
    startCommand: 'startCommand',
  },
};

Properties ​

codeConfigurationValuesoptionalIResolvable | CfnService.CodeConfigurationValuesPropertycode_configuration_valuesoptionaltyping.Union[IResolvable, CodeConfigurationValuesProperty]codeConfigurationValuesoptionalIResolvableCodeConfigurationValuesoptionalIResolvableCodeConfigurationValuesoptionalinterface{}#
The basic configuration for building and running the App Runner service.

Use it to quickly launch an App Runner service without providing a apprunner.yaml file in the source code repository (or ignoring the file if it exists).

configurationSourcestringconfiguration_sourcestrconfigurationSourceStringConfigurationSourcestringConfigurationSource*stringrequired#
The source of the App Runner configuration. Values are interpreted as follows:.
notes
  • REPOSITORY – App Runner reads configuration values from the apprunner.yaml file in the source code repository and ignores CodeConfigurationValues .
  • API – App Runner uses configuration values provided in CodeConfigurationValues and ignores the apprunner.yaml file in the source code repository.