FROM node
ENV MONGO_DB_USERNAME=admin \
MONGO_DB_PASSWORD=qwerty
RUN mkdir -p /home/app
COPY . /home/app
CMD ["node", "/home/app/server.js"]test-app folder during development and can run:node server.jsserver.js exists in the same location./home/app/server.jsdocker build -t test-app:1.0 .-t → tag (image name + version)test-app:1.0 → image name and version. → current directory (where Dockerfile exists)test-app folder because that is where the Dockerfile is located.docker imagestest-app:1.0mongomongo-expressdocker run test-app:1.0Server running on port 5050docker run -it test-app:1.0 /bin/bashlstest-app folder and all files have been successfully copied into the containerdocker build creates an image from the Dockerfiledocker run starts a container from the image/home/app inside the containerCMD