When I debug my Dockerfile, y constantly need to run these two commands:
$ docker build -t myuser/myapp:mytag - < myapp.docker
$ docker run -i -t myuser/myapp:mytag /bin/bash
("mytag" is usually something like "production", "testing" or "development". Not sure if I should use tags this way)
But now the second command no longer works: it starts the old container. If I list all containers with $ docker images, I see my labeled container in third place and other unlabeled containers in front of it. If I use the identifier of the 1st container, it works fine, but it will be annoying to do it this way, I have to look for its identifier every time.
What am I doing wrong?
source
share