Skip to content
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
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM node:8.14.0-alpine
copy index3.js ./
RUN npm install express mysql
CMD node index3.js
EXPOSE 3010
51 changes: 31 additions & 20 deletions answers.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,52 @@
# Answers

Lastname:
Firstname:
Lastname:BERTHET BONDET
Firstname: Aldric

## 2.2
command:
command: docker run aldric

## 2.3
question:
command:
question: L'accès n'est pas autorisé pour cause de port non ouvert. Il faut alors relancer notre container en ouvrant le port concerné
command: sudo docker run -p 3000:3000 -td aldric

## 2.5
question:
command:
question: Il faut changer le tag
command: docker tag 77d21cd3e40d hogun/devops-lab:latest
command: docker push hogun/devops-lab:latest

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

question:
command:
question: il faut pull l'image
command: sudo docker pull hogun/devops-lab

command:
command: sudo docker create hogun/devops-lab
command: sudo docker run --detach hogun/devops-lab

## 2.7
question:
question:
command:
question: Nom du fichier actuel : goofy_zhukovsky
question: On renomme le fichier avec le nom : api_web_js

command: sudo docker ps -a
command: sudo docker rename goofy_zhukovsky api_web_js


command:

## 2.8
question:
output:
question: NAme : ALpine Linux
output:
3.8.1
NAME="Alpine Linux"
ID=alpine
VERSION_ID=3.8.1
PRETTY_NAME="Alpine Linux v3.8"
HOME_URL="http://alpinelinux.org"
BUG_REPORT_URL="http://bugs.alpinelinux.org"

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

## 3.4
command:
command:
command: sudo docker-compose up -d
command: sudo docker-compose logs
16 changes: 16 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
version: '3'
services:
my-service:

ports:
- "3000:3000"

environment:
- MYSQL_HOST=localhost
- MYSQL_LOGIN=root
- MYSQL_PASSWORD=root
- MYSQL_DATABASE=zoo
- MYSQL_PORT=3307

image: hogun/devops-lab

Loading