ฉัน deployng Fargate การบริการผ่า AWS CDK บอย่างง่ายดาย
ตอนนี้ฉันต้องการจะปรับปรุงบริการสำหรับตัวอย่างเป็นงานของภาพ.
-ลอตโซ่มีบางอพยายามจะย่อมทำเรื่องนี้โดยใช้@aws-cdk/aws-codepipeline และการกระทำ EcsDeployAction
ฉันกำลังพยายามนำเข้าและปรับปรุงที่มีอยู่แล้ว(ความเดิมตอนที่แล้วย้ายไป)fargate บริการเหมือนนี้:
const pipeline = new codepipeline.Pipeline(this, 'MyPipeline')
// import an existing fargate service
const fargateService = ecs.FargateService.fromFargateServiceArn(
this,
"FargateService",
"MyFargateServiceARN"
);
// Deploy a new version according to what
const sourceStage = this.pipeline.addStage({
stageName: 'Deploy',
actions: [
new codepipeline_actions.EcsDeployAction({
actionName: "ECS-Service",
service: fargateService, <--- here the typescript error
input: ...
})
]
})
แต่มันไม่ดูเหมือนถูกต้องเพราะผมได้รับ typescript เกิดข้อผิดพลาด:
Property 'cluster' is missing in type 'IFargateService' but required in type 'IBaseService'
รู้บ้างมั้ย?