Cleaning up #313
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I don't really know if this is an issue for docs or abra. The problem is this: When deploying and then undeploying, and when updating, docker images and volumes are not properly deleted from the server. This means that the drive gets used pretty fast, if you play around with recipies to test out apps, and when you update. Often, I have experienced that containers have status DEAD - not something it was easy to find information about on the net. This means that I could not delete apps I no longer used.
By trial and error, I found out that I could use the following commands:
docker ps -a: list all containers, and identify DEAD or exited ones.docker rm <list-of-container-ids or -names>: remove these dead containers.docker volume ls: list volumes.docker volume rm <list-of-volumes>: Remove volumes (but not possible if they were in "use" by DEAD containersdocker image ls: list images - a lot of them might not be in use - and they take up a lot of space.docker image rm <list-of-images>: Removes unused images.Then you can go back to abra and
abra app remove <app>.I guess it would be a good idea to improve the cleaning-up when stopping and removing and updating apps (or maybe I just overlooked something).
But it might also be an idea to add something like the above to the documentation somewhere?
Ah, have you tried
docker system prune? We also haveabra server prune. It would be good to have documentation on this! In general, stuff needs to be undeployed to be cleaned up by Docker tooling.