0

I created some containers on my system (ubuntu 14.04) using docker-compose which mounted directories from the host into the containers. Now, every time I reboot the host, these directories are recreated, even though the containers do not longer exist (and I therefore deleted the directory).

Example: I had a container for gitlab-ci in

/var/docker/gitlab-ci/

Containing the files/directories

docker-compose.yml
data/
postegresql/

I have deleted the directory

gitlab-ci/

now,

gitlab-ci/data
gitlab-ci/postgresql

are created after every reboot. How do I get rid of them?

Martin
  • 2,754
  • 1
  • 15
  • 35

1 Answers1

0

Those containers might still exists. What does the docker ps -a command shows?

If you can still see your gitlab related containers, remove them with docker rm -f <container name>, then delete the directories and reboot to check if they appear again.

If you still have your docker-compose.yml file, then you could have removed those containers with:

docker-compose stop
docker-compose rm
Thomasleveil
  • 95,867
  • 15
  • 119
  • 113