I create a docker image with two echos but only the last one is displayed:
dockerfile:
FROM ubuntu:20.04
ENV DEBIAN_FRONTEND=noninteractive
CMD echo "HELLO WORLD"
CMD echo "GOODBYE WORLD"
build and run:
docker build -t junk:junk .
docker run -it junk:junk
The output is
GOODBYE WORLD
How can I control the output of docker run -it
?