EMERGING TRENDS IN SOFTWARE ENGINEERING
DEVOPS
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
You need to create a Docker container based on nginx image and need to root prompt of the container. Which command would help you achieve it?
|
docker run-it nginx /bin/bash
|
|
docker container run-it nginx
|
|
docker container run-d nginx
|
|
docker container run-itd ____ name=web nginx
|
|
docker exec-it nginx:latest /bin/bash
|
Explanation:
Detailed explanation-1: -To start your Nginx Docker container, run this command: docker run–name docker-nginx-p 80:80 nginx.
Detailed explanation-2: -Set Up Docker on Your Computer. If you haven’t already, create a DockerHub account and install Docker on your computer. Explore Docker Containers (optional) Create a Dockerfile. Build, Name, and Tag the Image. Test Locally. Push to DockerHub. Running Jobs.
There is 1 question to complete.