docker – The container name “/smoke-test-rabbitmq-1” is already in use by container… – Github Actions

I have an action that spins up some containers to run a smoke test, but the last time it failed, and now every time I try to run the action again, it shows this message. How can I fix it?

Error response from daemon: Conflict. The container name "/smoke-test-rabbitmq-1" is already in use by container "vcd13aceb9c2cc1ab5348b84f8245b4d0fe639471914392ec5dd7a3ec373464". You have to remove (or rename) that container to be able to reuse that name.

The problem with this is that it’s a GitHub action, and I can’t stop the containers unless I keep executing code. Even testing with ‘act’ locally, it still generates errors

Read more here: Source link