Slide 41
Slide 41 text
AWS ECS
Task Role
const springBootTaskRole = new iam.Role(this, 'SpringBoot TaskRol
assumedBy: new iam.ServicePrincipal('ecs-tasks.amazonaws.com'),
roleName: 'springboot-task-role',
inlinePolicies: {
'allow-discover-task-policy': new iam.PolicyDocument({
statements: [
new iam.PolicyStatement({
actions: [
'ecs:ListTasks',
'ecs:DescribeTasks',
'ec2:DescribeNetworkInterfaces',
],
resources: ['*'],
})]})}})