Removing a container starting with an explicit name
Containers that start with a name parameter are not automatically removed even if you specify the --rm
argument. To remove a container started in this way, we must manually use the docker rm
command. If we append the -v
option to the command, we can also remove the volumes that are associated with it. We should really do this now, or when we try to recreate the container later in the chapter, you might be left a little puzzled:
$ docker rm -v server