Reputation: 71
Im trying to create a Jenkins/Fargate build pipeline. The idea would be that Jenkins would build and when it needs slaves it would ask Fargate to for the slave resources and do the work. Currently have it set up to do the same thing using ECS but I feel there is a step in missing. This is all done via the console and not awscli.
Jenkins setup is as follows: - version 2.121.2 - default plugins and ecs plugin 1.19
AWS setup: - IAM with - AmazonEC2ContainerRegistryFullAccess - AmazonECS_FullAccess - AmazonECSTaskExecutionRolePolicy - Fargate setup added via images fargate
The jenkins plugin picks up the ecs/fargate cluster with the correct details. When I do run a but I always get the following error of "(pending—Jenkins doesn’t have label ecs-slaves)".
Upvotes: 2
Views: 2637
Reputation: 11
I had the same problem until I created my own task definition in the AWS console, and then use the "Task Definition Override" option in the Jenkins plugin to specify my task definition name. This will ignore all task settings you have entered in the plugin UI and instead utilize the task from your task definitions in AWS. You don't have to create an ECS service, the plugin will do that for you.
Upvotes: 1