> **Experimental**
>
> `@aws-cdk/aws-apprunner-alpha` is an [**experimental**](/stability) (alpha) package: its API may change in any release, without a major version bump.
# CodeConfiguration

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

- Stability: [Experimental](/cdk/api/stability.html)
- Source: [`lib/service.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0-alpha.0/packages/@aws-cdk/aws-apprunner-alpha/lib/service.ts#L806)

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as apprunner_alpha from '@aws-cdk/aws-apprunner-alpha';

declare const runtime: apprunner_alpha.Runtime;
declare const secret: apprunner_alpha.Secret;
const codeConfiguration: apprunner_alpha.CodeConfiguration = {
  configurationSource: apprunner_alpha.ConfigurationSourceType.REPOSITORY,

  // the properties below are optional
  configurationValues: {
    runtime: runtime,

    // the properties below are optional
    buildCommand: 'buildCommand',
    environment: {
      environmentKey: 'environment',
    },
    environmentSecrets: {
      environmentSecretsKey: secret,
    },
    environmentVariables: {
      environmentVariablesKey: 'environmentVariables',
    },
    port: 'port',
    startCommand: 'startCommand',
  },
};
```

## Properties

- `configurationSource`: [ConfigurationSourceType](/cdk/api/v2/docs/@aws-cdk_aws-apprunner-alpha.ConfigurationSourceType.html) (required) — The source of the App Runner configuration.

- `configurationValues`: [CodeConfigurationValues](/cdk/api/v2/docs/@aws-cdk_aws-apprunner-alpha.CodeConfigurationValues.html) — The basic configuration for building and running the App Runner service.

  **Default:** not specified. Use `apprunner.yaml` instead.

  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).
