Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

EntityAlreadyExists error when creating a service #87

Open
gmcguire opened this issue May 16, 2019 · 1 comment
Open

EntityAlreadyExists error when creating a service #87

gmcguire opened this issue May 16, 2019 · 1 comment

Comments

@gmcguire
Copy link

When creating a service in an empty cluster, I'm seeing the following error:

EntityAlreadyExists: Role with name ecsTaskExecutionRole already exists.
	status code: 409, request id: 6eb085be-77e1-11e9-a00c-09daa6044045

It looks like for whatever reason the GetRole call in CreateEcsTaskExecutionRole isn't finding the existing role, and tries to recreate it.

https://github.com/jpignata/fargate/blob/master/iam/role.go#L28

If I delete the role, this code recreates it correctly, but the next service I try to add hits the same error.

@joshenders
Copy link

joshenders commented Dec 26, 2020

Also experiencing this issue. It seems to happen for me when fargate task run fails before launching a container. You can repro this by running fargate with a new IAM user with enough IAM policy grants to create the ecsTaskExecutionRole but nothing else.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants