Docker run Nginx
Run Nginx
1 | docker run -d -p 1324:80 --name mynginx nginx |
Using Dockerfile Create Nginx & Run Nginx
Creat Docker file
Dockerfile
1 | FROM nginx |
index.html
1 | <!DOCTYPE html> |
build docker imgage
1 | docker build -t mynginx:1 . |
Run mynginx
1 | docker run -d --name mynginx -p 1234:80 mynginx:1 |