-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdocker5.txt
More file actions
23 lines (21 loc) · 1017 Bytes
/
docker5.txt
File metadata and controls
23 lines (21 loc) · 1017 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Prob-:
1. What is dockerfile
2. How to create Dockerfile
3. How to build image from Dockerfile
4. Basic Commands
Dockerfile-:
A textfile with instructions to build image
Automation of Docker Image Creation
Step1 - Create a file named Dockerfile >> mkdir "dir-name"
cd dir-name/
touch Dockerfile-name
vim Dockerfile-name
Step2 - Add instructions in Dockerfile >>
FROM imagename
MAINTAINER yourname <your-email>
RUN apt-get update
CMD [" gffdsfdsfw "]
Step3 - Build dockerfile to create image >>
docker build -t name_of_image:tag .
Step4 - Run image to create container >>
docker run image-id