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

make clean not removing containers properly #13

Open
joewxboy opened this issue Feb 25, 2020 · 1 comment
Open

make clean not removing containers properly #13

joewxboy opened this issue Feb 25, 2020 · 1 comment
Labels
bug Something isn't working

Comments

@joewxboy
Copy link
Member

When I run make clean in the hub/oh folder, I get the following output, which suggests the images and containers are not being removed:

root@joe-oh-hub-svcs1:~/open-horizon-integration/hub/oh# make clean
docker rm -f "agbot"
Error: No such container: agbot
makefile:244: recipe for target 'remove' failed
make: [remove] Error 1 (ignored)
docker rm -f "exchange-api"
Error: No such container: exchange-api
makefile:244: recipe for target 'remove' failed
make: [remove] Error 1 (ignored)
docker rm -f "css-api"
Error: No such container: css-api
makefile:244: recipe for target 'remove' failed
make: [remove] Error 1 (ignored)
docker rm -f "exchange-db"
Error: No such container: exchange-db
makefile:244: recipe for target 'remove' failed
make: [remove] Error 1 (ignored)
docker rm -f "css-db"
Error: No such container: css-db
makefile:244: recipe for target 'remove' failed
make: [remove] Error 1 (ignored)
sudo rm -fr /root/open-horizon-integration/hub/oh/docker-compose.yml css agbot exchange

Maybe the names have changed?

@joewxboy joewxboy added the bug Something isn't working label Feb 25, 2020
@haveroot
Copy link

The following options do not have a dependency on names.

Suppose all containers of Open Horizon carry a label such as org.openhorizon. Then, we can clean them up with (untested) command docker rm $(docker ps -a -f label=org.openhorizon). Another option could be the removal of containers based on the ancestor filter to list containers off of an image.

For more details on filtration of ps command output, see here.

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

No branches or pull requests

2 participants