Docker Nginx Commands Quiz
5 Questions
0 Views

Docker Nginx Commands Quiz

Created by
@LawfulAsteroid

Questions and Answers

Which command will correctly run a container from the nginx image with the name my-nginx?

  • docker run --name my-nginx nginx (correct)
  • docker start my-nginx nginx
  • docker create --name nginx my-nginx
  • docker launch my-nginx from nginx
  • What is the purpose of the '--name' option in the command to run a container?

  • It sets the specified image to use.
  • It specifies the memory limit for the container.
  • It allows the user to assign a custom name to the container. (correct)
  • It automatically runs the container in detached mode.
  • Which command should you avoid if you want to run a new nginx container named my-nginx?

  • docker exec -it my-nginx bash
  • docker run nginx --name my-nginx (correct)
  • docker create --name my-nginx nginx
  • docker run --name my-nginx nginx
  • What is the expected result of running 'docker run --name my-nginx nginx'?

    <p>It will pull the nginx image if not already available.</p> Signup and view all the answers

    Which of the following commands correctly references the nginx image to run a container?

    <p>docker run --name my-nginx nginx:latest</p> Signup and view all the answers

    More Quizzes Like This

    Docker Platform Quiz
    15 questions

    Docker Platform Quiz

    HandierMossAgate9407 avatar
    HandierMossAgate9407
    04 - Docker Fundamentals
    18 questions

    04 - Docker Fundamentals

    EntrancedDobro6607 avatar
    EntrancedDobro6607
    Docker Commands Quiz
    24 questions

    Docker Commands Quiz

    RemarkableMeadow avatar
    RemarkableMeadow
    Use Quizgecko on...
    Browser
    Browser