jolly-alligator-19698
03/08/2022, 4:25 PMCreating EventBridge Target failed: ValidationException: Parameter(s) EcsParameters not supported for target
Here's the resource code. Is there an error in the code? Or a way to get more information about the failure? Thank you.
const eventTarget = pulumi.all([subnetIds.ids, taskDefinition.taskDefinition.arn, deadLetterQueue.arn])
.apply(([subnetIds, taskDefinitionArn, deadLetterQueueArn]) => new aws.cloudwatch.EventTarget("event-target", {
arn: deadLetterQueueArn,
name: `${pulumi.getProject()}-event-target`,
description: genericDescription,
ecsTarget: {
taskDefinitionArn: taskDefinitionArn,
enableEcsManagedTags: true,
enableExecuteCommand: true,
group: pulumi.getProject(),
launchType: "FARGATE",
networkConfiguration: {
assignPublicIp: false,
securityGroups: [securityGroupId],
subnets: subnetIds,
},
platformVersion: "1.4.0",
taskCount: 1,
},
eventBusName: "default",
retryPolicy: {
maximumEventAgeInSeconds: 60,
maximumRetryAttempts: 1,
},
rule: eventRule.name,
}, {provider: targetAwsProvider}));
pulumi.all([subnetIds.ids, taskDefinition.taskDefinition.arn, deadLetterQueue.arn])
.apply(([subnetIds, taskDefinitionArn, deadLetterQueueArn]) => console.log([subnetIds, taskDefinitionArn, deadLetterQueueArn]))
console.log(securityGroupId)
yields
sg-<redacted>
[
[ 'subnet-<redacted>', 'subnet-<redacted>' ],
'arn:aws:ecs:us-east-2:<redacted>:task-definition/task-definition-<redacted>:3',
'arn:aws:sqs:us-east-2:<redacted>:<redacted>'
]
stocky-restaurant-98004
03/08/2022, 4:52 PMarn
- that should point to the target ECS cluster.jolly-alligator-19698
03/08/2022, 4:57 PMconst eventRule = new aws.cloudwatch.EventRule("event-rule", {
name: `${pulumi.getProject()}-event-rule`,
description: genericDescription,
eventBusName: "default",
scheduleExpression: "cron(1 0 * * ? *)",
}, {provider: targetAwsProvider});
eventTarget.d.ts
docs define arn
as ARN of the SQS queue specified as the target for the dead-letter queue.
arn
to the cluster arn allowed the resource creation to finish. Thank you @stocky-restaurant-98004stocky-restaurant-98004
03/08/2022, 5:06 PM