File tree 1 file changed +9
-5
lines changed 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change 3
3
## Flow-1: Pull existing Docker Image from Docker Hub and Run it as a Container
4
4
5
5
## Flow-2: Create a new Docker Image, Run as Container and Push to Docker Hub
6
- ### Run the base Nginx container
6
+ ### Step-1: Run the base Nginx container
7
7
- Access the URL http://localhost
8
8
```
9
9
docker run --name mynginxdefault -p 80:80 -d nginx
10
10
docker ps
11
11
```
12
12
13
- ### Create Dockerfile and copy our customized index.html
13
+ ### Step-2: Create Dockerfile and copy our customized index.html
14
14
```
15
15
FROM nginx
16
16
COPY index.html /usr/share/nginx/html
17
17
```
18
- - Build Docker Image & run it
18
+
19
+ ### Step-3: Build Docker Image & run it
19
20
```
20
21
docker build -t stacksimplify/mynginx_image1:v1 .
21
22
docker run --name mynginx1 -p 80:80 -d stacksimplify/mynginx_image1:v1
22
23
```
23
- - Tag & push the Docker image to docker hub
24
+
25
+ ### Step-4: Tag & push the Docker image to docker hub
24
26
```
25
27
docker images
26
28
docker tag stacksimplify/mynginx_image1:v1 stacksimplify/mynginx_image1:v1-release
27
29
docker push stacksimplify/mynginx_image1:v1-release
28
30
```
29
- - Verify the same on docker hub
31
+ ### Step-5: Verify the same on docker hub
32
+ - Login to docker hub
33
+ - Url: https://hub.docker.com/repositories
You can’t perform that action at this time.
0 commit comments