200-901 exam dumps

200-901 practice question 120 of 204

Cisco DevNet Associate. Associate level, Cisco. Free question with the correct answer and a full explanation.

200-901 Question 120

Select 3

You are working on a Python application in your local development environment. You want to test the application using a containerized database without affecting your local system configuration. Which of the following steps should you perform to utilize a Docker image for this purpose?

  1. A

    Pull the required database Docker image from a container registry like Docker Hub.

  2. B

    Use the docker build command to create a custom Docker image for your Python application.

  3. C

    Run the database Docker container using the docker run command with appropriate ports and environment variables.

  4. D

    Install the database software directly on your local machine for faster integration.

  5. E

    Use Docker Compose to define and run both the Python application and database services together.

Show answer and explanation

Correct answers: A, C, E

Explanation

To utilize a Docker image for a database in your local developer environment, you need to pull the appropriate image, run the container to start the database service, and optionally use Docker Compose to manage the setup if multiple containers (such as an app and a database) are involved. This approach ensures isolation and avoids changes to your local system configuration.

  • A. Correct.

    Pulling the required Docker image is the first step to use a pre-built containerized database. This allows you to download the database image from a public or private registry.

  • B. Incorrect.

    Building a custom image for your Python application is unrelated to the task of utilizing a database Docker image and is not required in this scenario.

  • C. Correct.

    Running the database container using docker run enables you to start the database service and configure it, such as by exposing ports or setting environment variables.

  • D. Incorrect.

    Installing the database software on your local machine contradicts the goal of using Docker to avoid affecting your local configuration.

  • E. Correct.

    Using Docker Compose is a good practice to define and manage multi-container applications, such as a Python app that depends on a database.

Timed practice exam

Take a 200-901 practice test under exam conditions

75 questions in 120 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam