thousands-window-76079
04/15/2024, 3:29 PMconst service = new awsx.ecs.FargateService('templi-api', {
cluster: baseInfra.requireOutput('clusterArn'),
enableExecuteCommand: true,
networkConfiguration: {
securityGroups: [apiSecurityGroup.id],
assignPublicIp: true,
subnets: baseInfra.requireOutput('vpcPublicSubnetIds'),
},
taskDefinitionArgs: {
taskRole: {
roleArn: taskRole.arn,
},
container: {
name: 'templi-api',
image: apiImage.imageUri,
cpu: 128,
memory: 512,
essential: true,
portMappings: [
{
containerPort: 80,
targetGroup: blueTargetGroup,
},
],
},
},
});
Everytime I ran pulumi up
pulumi would build a new docker image, and update my service task definition accordingly
This worked great
But I have been a little bit disappointed when trying to use the same worfklow but with CodeDeploy as my deployment contrller
deploymentController: {
type: 'CODE_DEPLOY',
},
With accompanying code deploy infra provisioned, when running pulumi up
i get the following error
InvalidParameterException: Unable to update task definition on services with a CODE_DEPLOY deployment controller. Use AWS CodeDeploy to trigger a new deployment.
Which seems to be a limitation from AWS https://github.com/aws/aws-cdk/issues/1559 (which has since been resolved by a new L2 Construct in the CDK)
my question is, are the any plans/workarounds to support this in Pulumi? Or if anyone has any guidance on how I can proceed- do I provision just my task definition etc. via pulumi, and then use @pulumi/command
to run a aws deploy
?great-sunset-355
04/16/2024, 7:39 AM@pulumi/command
can help
https://dev.to/aws-builders/ecs-bluegreen-deployment-with-codedeploy-and-terraform-3gf1