Ansible Interview Questions and Answer – Part 10

How would you ensure your application is configured correctly for different types of tests?

  • This is not possible.
  • Create multiple configuration files for your application, one per type of test. (Ans)
  • Use multiple machines, one per type of test.
  • Clone multiple copies of your application, one per type of test.

Which statement best describes Docker Compose?

  • A file that describes how to build a single Docker image
  • Tooling that allows you to build a hierarchy of Docker images
  • Tooling that describes a multi-container environment and runs services in that environment (Ans)
  • A file that describes a multi-container environment

What format is used for AWS CloudFormation templates?

  • JavaScript
  • Groovy
  • JSON (Ans)
  • YAML

When you install a source distribution, which of the following tasks is required?

  • The distribution is extracted and copied to the target file system
  • The application source is built
  • All of these (Ans)
  • The application source is compiled

Which of the following describes how the Ansible module typically operates when using AWS modules?

  • Ansible connects to your local machine using a local connection, which then communicates with AWS services. (Ans)
  • Ansible connects to a remote host using HTTP, which then communicates with AWS services.
  • Ansible connects to a remote host using SSH, which then communicates with AWS services.
  • Ansible connects to your local machine using SSH, which then communicates with AWS services.

Which of the following are examples of clean up commands in a Docker Compose environment?

  • docker-compose kill
  • All of these (Ans)
  • docker-compose run –rm
  • docker-compose rm

Which of the following is created during the build stage?

  • Application Artifacts (Ans)
  • Docker Images
  • Virtual Machine Images
  • All of these

Which metadata property lists the current tags associated with an image?

  • CurrentLabels
  • RepoTags (Ans)
  • CurrentTags
  • RepoLabels

Which of the following represents the lowest level of automation in the continuous delivery workflow?

  • docker-compose commands
  • docker commands
  • make commands
  • Dockerfile directives (Ans)

Which of the following is used to automate creation of multi-container environments?

  • Docker Compose (Ans)
  • Docker Machine
  • Docker Engine
  • Docker Client

What is the first stage of a continuous delivery workflow?

  • Test (Ans)
  • Build
  • Release
  • Deploy

You would NOT typically use changes to the _ as a trigger for your continuous delivery workflow.

  • Application source code
  • Parent image of your base image
  • Development image (Ans)
  • Base image

What form of testing is performed during the release phase of continuous delivery?

  • Integration testing
  • Manual testing
  • Acceptance testing (Ans)
  • Unit testing

What is the best approach to speed up the installation process of application dependencies in a Docker container?

  • Create a cache folder in the container to cache downloaded dependencies.
  • Use a faster computer.
  • Use a volume container to cache downloaded dependencies. (Ans)
  • Use a faster Internet connection.

Which type of character is required to separate rules in a make target?

  • Space
  • Tab (Ans)
  • Comma
  • Colon

When is it acceptable to use volume mappings?

  • All of these
  • When you need to exchange files between Docker containers and the Docker Client
  • When you need to exchange files between Docker containers and the Docker Swarm Cluster
  • When you need to exchange files between Docker containers and the Docker Host (Ans)

Which docker-compose command can be used to override the settings of a defined service?

  • docker-compose up
  • docker-compose attach
  • docker-compose exec
  • docker-compose run (Ans)

Which type of volume would you use if you need to persist data across multiple workflow runs?

  • Internal Volume
  • Volume Mapping
  • Volume Container
  • External Volume (Ans)

Which of the following are examples of initialisation tasks you need to perform in the release environment?

  • Adding a required operating system package to the base image
  • Adding a required operating system package to the parent image
  • All of these
  • Populating the database with schema, tables and sample data (Ans)

Which of the following best describes an ECS Task?

  • An application process that runs and then exits
  • An application process that runs continuously
  • A Docker container that runs continuously
  • A Docker container that runs and then exits (Ans)

How do you reduce the size of the Docker build context?

  • Exclude unneeded folders using .dockerignore. (Ans)
  • Exclude unneeded folders in your Dockerfile.
  • This is not possible.
  • Exclude unneeded folders using .gitignore.
Rajesh Kumar
Follow me