Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lab done finally #144

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@

FROM node:8.14.0-alpine
COPY . /root
RUN npm install express mysql
CMD node /root/project.js
EXPOSE 3002
1 change: 1 addition & 0 deletions Readme.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
bonjour
58 changes: 40 additions & 18 deletions answers.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,63 @@
# Answers

Lastname:
Firstname:
Lastname:ALLINE
Firstname:Rémy

## 2.2
command:
command:sudo docker run app

## 2.3
question:
command:
question:The port is not open so it can' access it
command: sudo docker run -p 3000:3000 project.js

## 2.5
question:
command:
question:the local image name have to match the same as the repository
command:sudo docker tag project.js remyalline/devops_lab
sudo docker push remyalline/devops_lab

## 2.6
command:
command:sudo docker system prune -a

question:
command:
question: we pull the image with : sudo docker pull remyalline/devops_lab and after that we start a container with the same name as the one we pushed
command:sudo docker create remyalline/devops_lab

command:
command:sudo docker run --detach r/devops_lab

## 2.7
question:we can see the all the containers with their id, names, status and when they were created
the status of the congtainer is up
for this we used the command: sudo docker ps -a
the name of the container is quizzical_kirch

question:
question:
command:
command:sudo docker rename quizzical_kirch application

command:

## 2.8
question:
output:
question:the OS from the container is Ubuntu
output:DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.1 LTS"
NAME="Ubuntu"
VERSION="18.04.1 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.1 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic


## 3.1
command:
command:sudo docker-compose up

## 3.4
command:
command:
command:sudo docker-compose up -d
command:sudo docker-compose logs

5 changes: 5 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
version: '3'
services:
my-service:
image: remyalline/devops_lab

Loading