# CodeDeployEcsContainerImageInput

Configuration for replacing a placeholder string in the ECS task definition template file with an image URI.

- Source: [`aws-codepipeline-actions/lib/codedeploy/ecs-deploy-action.ts`](https://github.com/aws/aws-cdk/blob/v2.278.0/packages/aws-cdk-lib/aws-codepipeline-actions/lib/codedeploy/ecs-deploy-action.ts#L14)

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_codepipeline as codepipeline } from 'aws-cdk-lib';
import { aws_codepipeline_actions as codepipeline_actions } from 'aws-cdk-lib';

declare const artifact: codepipeline.Artifact;
const codeDeployEcsContainerImageInput: codepipeline_actions.CodeDeployEcsContainerImageInput = {
  input: artifact,

  // the properties below are optional
  taskDefinitionPlaceholder: 'taskDefinitionPlaceholder',
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_codepipeline as codepipeline
from aws_cdk import aws_codepipeline_actions as codepipeline_actions

# artifact: codepipeline.Artifact

code_deploy_ecs_container_image_input = codepipeline_actions.CodeDeployEcsContainerImageInput(
    input=artifact,

    # the properties below are optional
    task_definition_placeholder="taskDefinitionPlaceholder"
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.codepipeline.*;
import software.amazon.awscdk.services.codepipeline.actions.*;

Artifact artifact;

CodeDeployEcsContainerImageInput codeDeployEcsContainerImageInput = CodeDeployEcsContainerImageInput.builder()
        .input(artifact)

        // the properties below are optional
        .taskDefinitionPlaceholder("taskDefinitionPlaceholder")
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CodePipeline;
using Amazon.CDK.AWS.CodePipeline.Actions;

Artifact artifact;

var codeDeployEcsContainerImageInput = new CodeDeployEcsContainerImageInput {
    Input = artifact,

    // the properties below are optional
    TaskDefinitionPlaceholder = "taskDefinitionPlaceholder"
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

var artifact Artifact

codeDeployEcsContainerImageInput := &CodeDeployEcsContainerImageInput{
	Input: artifact,

	// the properties below are optional
	TaskDefinitionPlaceholder: jsii.String("taskDefinitionPlaceholder"),
}
```

## Properties

- `input`: [Artifact](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_codepipeline.Artifact.html) (required) — The artifact that contains an `imageDetails.json` file with the image URI.

  The artifact's `imageDetails.json` file must be a JSON file containing an
  `ImageURI` property.  For example:
  `{ "ImageURI": "ACCOUNTID.dkr.ecr.us-west-2.amazonaws.com/dk-image-repo@sha256:example3" }`

- `taskDefinitionPlaceholder`: string = IMAGE — The placeholder string in the ECS task definition template file that will be replaced with the image URI.

  The placeholder string must be surrounded by angle brackets in the template file.
  For example, if the task definition template file contains a placeholder like
  `"image": "<PLACEHOLDER>"`, then the `taskDefinitionPlaceholder` value should
  be `PLACEHOLDER`.
