I'm fairly new to Docker. I have a long Dockerfile that I inherited from a previous developer, which has many errors and I'm trying to get it back to a working point. I commented out most of the file except for just the first line:
FROM ubuntu:14.04
I did the following:
docker build -t pm .to build the image - this works because I can see the image when I executedocker imagesdocker run <image-id>returns without error or any message. Now I'm expecting the container to be created from the image and started. But when I do adocker ps -ait shows the container exited:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMESb05f9727f516 f216cfb59484 "/bin/bash" About a minute ago Exited (0) About a minute ago
lucid_shirley
Not sure why can't I get a running container and why does it keep stopping after the docker run command.
- executing
docker logs <container_id>displays nothing - it just returns without any output.