Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't delete ECR RepositoryPolicy for non-existent repository #714

Closed
negz opened this issue Jun 12, 2021 · 3 comments · Fixed by #721
Closed

Can't delete ECR RepositoryPolicy for non-existent repository #714

negz opened this issue Jun 12, 2021 · 3 comments · Fixed by #721
Labels
bug Something isn't working

Comments

@negz
Copy link
Member

negz commented Jun 12, 2021

What happened?

I'm spinning up and down all of our examples in order to run some Crossplane conformance tests. My suspicion is that deleting the repository automatically deletes the policy, but Crossplane's logic for deleting the policy requires the repository to exist. Perhaps if we can't find the repository the policy should apply to when deleting we should just consider it gone? That would be around this area I think - https://github.com/crossplane/provider-aws/blob/84acbf60/pkg/controller/ecr/repositorypolicy/controller.go#L100

Disclaimer: I haven't dug deep here and am making some assumptions about how ECR repos and policies work.

How can we reproduce it?

I notice that I can kubectl apply -f examples/ecr at successfully, but I can't kubectl delete -f the same directory.

What environment did it happen in?

Crossplane version :1.2.2
provider-aws commit: 84acbf6

@negz negz added the bug Something isn't working label Jun 12, 2021
@negz
Copy link
Member Author

negz commented Jun 12, 2021

CC @enderv, as I notice you built this managed resource out originally.

@enderv
Copy link
Contributor

enderv commented Jun 14, 2021

@negz took a quick poke think you are correct. I should have some time this week to try to get a fix up

@negz
Copy link
Member Author

negz commented Jun 15, 2021

@enderv Thank you!

@negz negz closed this as completed in #721 Jun 15, 2021
tektondeploy pushed a commit to gtn3010/provider-aws that referenced this issue Mar 12, 2024
…quest/patch

Bump native provider to version 4.67.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants