Lastname: MICHEL Firstname: Maxime Partner: PRAT Arthur
command: "~\devops-lab> docker run app Example app listening on port 3000!"
question: The call fails because the port 3000 is not exposed. We add an "EXPOSE 3000" line in the Dockerfile and use the -P option to dynamically expose the port at launch. command: docker run -P app
command: docker run -P -e MYSQL_HOST=localhost -e MYSQL_PORT=3306 -e MYSQL_USER=root -e MYSQL_PASSWORD="" -e MYSQL_DATABASE=zoo app
question: we have to tag the app with the corresponding remote name ("zoo"). We push it afterwards to egglestron/zoo. command: docker login docker tag app zoo docker push egglestron/zoo
command: docker system prune
commands: docker pull egglestron/zoo docker create egglestron/zoo docker run egglestron/zoo
command: docker ps
output: CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES fcf9b525d387 egglestron/zoo "/bin/sh -c 'node /r…" 40 seconds ago Up 38 seconds 3000/tcp thirsty_jepsen 45ff8001f8c7 egglestron/zoo "/bin/sh -c 'node /r…" 49 seconds ago Created thirsty_albattani
question: question: command:
command:
question: The OS of the container is Debian, a Linux distribution. output: PRETTY_NAME="Debian GNU/Linux 9 (stretch)" NAME="Debian GNU/Linux" VERSION_ID="9" VERSION="9 (stretch)" ID=debian HOME_URL="https://www.debian.org/" SUPPORT_URL="https://www.debian.org/support" BUG_REPORT_URL="https://bugs.debian.org/"
command: docker-compose up
command: docker-compose up -d command: docker-compose logs