Courseiva

200-901 · domain

Application Deployment and Security

Practise Cisco DevNet Associate 200-901 Application Deployment and Security practice questions — original exam-style scenarios with answer choices, explanations, and analysis of common mistakes.

99 questions21 easy50 medium28 hard

Focused practice

Practice Application Deployment and Security questions

Scored sessions drawing only from this domain — pick a length below.

Start 20-question practice test →

What this domain covers

What to know about Application Deployment and Security

Application Deployment and Security questions test whether you can apply the concept in context, not just recognise a definition.

How the topic appears in realistic exam-style scenarios.

Which detail in the question changes the correct answer.

How to eliminate plausible but wrong options.

How to connect the question back to the wider exam objective.

Watch out for

Common Application Deployment and Security exam traps

  • Answering from memory before reading the full scenario.
  • Missing a constraint such as cost, availability, security, scope or command context.
  • Choosing a broad answer when the question asks for the most specific fix.
  • Ignoring why the wrong options are tempting.

Question index

All Application Deployment and Security questions (99)

Click any question to see the full explanation, or start a practice session above.

1

Which TWO practices help prevent hardcoded credentials in application code? (Choose TWO.)

Medium
2

A CI/CD pipeline has a stage that runs security vulnerability scans on dependencies. Which tool is specifically designed to scan Python packages for known vulnerabilities?

Medium
3

Which TWO Docker network drivers allow a container to communicate with the host's network stack directly?

Medium
4

A Kubernetes pod has two containers: a main application and a sidecar proxy. They need to communicate via localhost. Which pod networking model allows this?

Hard
5

You are writing a Dockerfile for a Python application. Which instruction should you use to install the dependencies from a requirements.txt file?

Easy
6

A developer needs to share a Docker image with a colleague. They decide to push the image to a registry. Which Docker command pushes an image to a registry?

Easy
7

Which Docker network driver allows a container to share the host's network stack, giving it direct access to host interfaces?

Easy
8

Which THREE steps are essential in a typical CI/CD pipeline for a containerized application? (Choose THREE.)

Hard
9

A CI/CD pipeline uses GitHub Actions. The workflow should trigger only when a pull request is opened against the 'main' branch. Which 'on' trigger configuration is correct?

Hard
10

A Docker container running a web application needs to be accessible on the host's port 8080. The application inside the container listens on port 80. Which docker run command achieves this?

Medium
11

A developer wants to run a Docker container in detached mode, mapping host port 8080 to container port 80, and mounting a host directory for persistent data. Which command accomplishes this?

Medium
12

In a Kubernetes deployment, a developer needs to expose a set of pods internally within the cluster on a stable IP address. The pods are stateless and serve HTTP traffic. Which Service type should be used?

Medium
13

A company deploys a microservice using Kubernetes. The service must be accessible externally via a stable IP address and load-balanced across pods. Which Service type should be used?

Medium
14

A Kubernetes deployment is configured with replicas: 3. During a rolling update, the deployment strategy is set to RollingUpdate with maxSurge: 1 and maxUnavailable: 0. What is the maximum number of pods that will be running during the update?

Hard
15

A team is deploying a microservice that must scale independently. The service uses environment variables for configuration. Which Kubernetes resource should be used to store non-sensitive configuration data separate from the container image?

Medium
16

In a Kubernetes cluster, you need to store non-sensitive configuration data (e.g., database hostname) that can be consumed by pods as environment variables. Which resource should you use?

Hard
17

A CI/CD pipeline for a Python project should run unit tests and check for known vulnerabilities in dependencies. Which tool can be integrated into the pipeline to perform dependency scanning?

Medium
18

A developer creates a Dockerfile for a Python web application. Which instruction should be used to define the working directory inside the container for subsequent commands?

Easy
19

In a Kubernetes cluster, you need to expose a set of pods running a web application to external traffic on a specific port. Which Service type should you use to provide a stable external IP address?

Hard
20

A Kubernetes administrator wants to use kubectl to troubleshoot a pod named 'my-pod' that is not starting. Which TWO commands are useful? (Choose two.)

Hard
21

A Kubernetes pod runs two containers that need to share a filesystem. Which volume type should be used to enable file sharing between the containers within the same pod?

Medium
22

A developer is writing a web application and needs to prevent SQL injection attacks. Which coding practice is most effective?

Medium
23

A company uses GitHub Actions for CI/CD. They want to automatically scan dependencies for known vulnerabilities on every push. Which action should be added to the workflow?

Hard
24

A CI/CD pipeline is configured to build a Docker image, run unit tests, and push the image to a registry. To ensure that only successfully tested images are pushed, which stage order is correct?

Hard
25

A web application is vulnerable to SQL injection. Which secure coding practice should the developer implement in the code to prevent this?

Medium
26

Which Docker networking mode provides the most isolation by not connecting the container to any network?

Easy
27

A Kubernetes cluster runs a microservice that needs to read configuration values from a ConfigMap and sensitive database credentials from a Secret. The pod manifest references both resources. How should the Secret be mounted to avoid exposing sensitive data in logs or environment variables?

Hard
28

A developer has a Docker container running a database. They need to inspect the database logs to debug a connection issue. Which command will show the logs in real-time?

Hard
29

A developer is creating a Dockerfile for a Python Flask application. The application runs on port 5000. Which directive should be used to document that the container listens on this port?

Easy
30

A Docker container needs to be started in detached mode with port mapping from host port 8080 to container port 80. Which command accomplishes this?

Easy
31

Which THREE options are valid methods to expose a Kubernetes service to external traffic?

Hard
32

A developer is writing a Dockerfile for a Node.js application. Which TWO instructions are commonly used to define the command that runs when the container starts?

Medium
33

Which Docker command is used to view the logs of a running container in real-time?

Easy
34

Which TWO practices help prevent sensitive data exposure in a CI/CD pipeline? (Select two.)

Easy
35

A Kubernetes Service must expose a pod running a database to other pods in the same cluster, but not externally. Which Service type should be used?

Hard
36

A developer runs the command: docker run -d -p 8080:80 --name web nginx. Which of the following best describes what happens?

Easy
37

A CI/CD pipeline for a microservice application includes stages: code commit, build Docker image, push to registry, deploy to staging, run integration tests, and deploy to production. The team wants to ensure that if integration tests fail, the pipeline stops and does not proceed to production. Which CI/CD concept is used to enforce this behavior?

Medium
38

A Kubernetes pod needs to read configuration data such as database hostname, which is non-sensitive and may change across environments. Which resource should be used to store this data and inject it into the pod?

Medium
39

In a Docker Compose file, you want to ensure that the 'web' service starts only after the 'db' service is healthy. Which key should you use under the 'web' service?

Medium
40

Which TWO commands are used to view information about Docker containers? (Select two.)

Medium
41

In a docker-compose.yaml file, which key is used to define the container image to be built from a Dockerfile in the current directory?

Easy
42

In a Dockerfile, which instruction is used to set an environment variable that will be available at runtime?

Easy
43

A Kubernetes Deployment manages a set of identical pods. You update the container image to a new version. The rollout gets stuck. Which kubectl command should you use to view the rollout status and determine the cause?

Hard
44

A developer writes a web application that accepts user input and displays it on a page. To prevent cross-site scripting (XSS), what is the most effective defense?

Medium
45

A developer needs to enforce HTTPS for a web application. Which security measure should be implemented in the application or reverse proxy?

Easy
46

A CI/CD pipeline includes stages for security scanning. Which TWO tools or services are specifically designed for dependency vulnerability scanning?

Medium
47

A Kubernetes environment has multiple teams sharing the same cluster. One team wants to deploy applications without interfering with other teams' resources. Which Kubernetes resource should be used to isolate the team's resources?

Medium
48

In a Docker Compose file with multiple services, one service depends on another to be healthy before starting. Which key should be used to express this dependency and ensure the dependent service is started first?

Hard
49

A developer uses Kubernetes and wants to expose a deployment named 'web-app' externally via a cloud load balancer. Which Service type should be used?

Hard
50

In a Kubernetes cluster, a developer needs to ensure that a set of pods can be accessed by other pods using a stable IP address and DNS name, even if pods are recreated. Which resource should be created?

Medium
51

A developer wants to run a container in the background with port mapping and a named volume. Which command accomplishes this?

Easy
52

A Kubernetes pod needs to run a database that requires persistent storage. Which volume type should be used to store data that persists beyond the pod lifecycle?

Hard
53

A developer is writing a Dockerfile for a Node.js application. The application uses environment variables for configuration. Which Dockerfile instruction should be used to set a default value for the NODE_ENV variable?

Medium
54

A developer needs to store a database password securely in a Kubernetes cluster. Which resource should be used?

Medium
55

A Kubernetes pod contains two containers that need to share a local filesystem. Which volume type should be used to enable this?

Medium
56

A CI/CD pipeline uses GitLab CI. The pipeline must build a Docker image and then run security scans on the image before pushing. Which GitLab CI keyword allows defining a sequence of jobs that must run in order?

Medium
57

A developer creates a Dockerfile for a Python web application. Which instruction should be used to copy the application source code into the container image?

Easy
58

A Kubernetes cluster has a deployment named 'frontend' that needs to be updated to a new image version. The update should be performed with zero downtime. Which three kubectl commands or approaches can achieve this? (Choose three.)

Medium
59

In a Docker Compose file, a service 'web' depends on 'db'. The 'db' service uses a volume to persist data. Which compose key ensures that the database starts before the web service?

Medium
60

A developer needs to view the logs of a running Docker container with ID 'abc123'. Which command should be used?

Medium
61

A developer is building a web application and wants to implement security best practices. Which TWO actions should be taken? (Choose two.)

Medium
62

In a Jenkins declarative pipeline, a stage named 'Deploy to Production' should only run after manual approval. Which directive should be used to achieve this?

Hard
63

A developer needs to ensure that environment variables containing database credentials are not hardcoded in the application code. Which approach is most secure for managing secrets in a CI/CD pipeline?

Medium
64

A CI/CD pipeline using GitHub Actions needs to build a Docker image and push it to Docker Hub. Which event trigger should be used to run the workflow only when code is pushed to the main branch?

Hard
65

A developer needs to share a Docker image built from a Dockerfile with team members. Which command correctly builds the image and tags it as 'myapp:v1'?

Medium
66

A developer wants to ensure that a containerized application restarts automatically if it exits with a non-zero code. The application is run using Docker. Which flag should be used?

Hard
67

A Kubernetes Deployment is configured with rolling update strategy. A new version of the image is pushed, and the deployment is updated. During the rollout, the new pods are failing health checks. Which command can be used to pause the rollout and prevent further updates?

Hard
68

A Kubernetes Deployment is updated with a new image tag, but the rollout fails. Which kubectl command should be used to view the rollout status and troubleshoot?

Medium
69

A developer is writing a Dockerfile for a Node.js application. They want to set a build-time variable for the application version that can be changed without modifying the Dockerfile. Which instruction should be used?

Medium
70

A developer notices that after a new deployment, the application is not receiving traffic. The Service selector does not match the pod labels. Which kubectl command can be used to inspect the Service's selector?

Hard
71

A team uses a Jenkins declarative pipeline to deploy a microservice. The pipeline includes stages: Checkout, Build Docker Image, Run Unit Tests, Push to Registry, Deploy to Staging, and Deploy to Production. Which stage should run immediately after 'Build Docker Image' to ensure code quality before the image is pushed?

Medium
72

You are writing a Dockerfile. Which instruction should you use to set the working directory for subsequent RUN, CMD, ENTRYPOINT, COPY, and ADD instructions?

Easy
73

Which TWO actions are best practices for managing secrets in a CI/CD pipeline?

Medium
74

A developer is using Docker Compose to run a multi-service application. Which THREE keys are valid top-level keys in a docker-compose.yml file? (Choose three.)

Medium
75

A developer needs to apply a Kubernetes deployment manifest from a file named 'deployment.yaml'. Which kubectl command should be used?

Medium
76

A developer commits code to a GitHub repository and wants automated tests to run, followed by building a Docker image and pushing it to Docker Hub only if tests pass. Which CI/CD tool can be configured using a YAML file placed in the .github/workflows directory?

Medium
77

A developer needs to prevent SQL injection in a web application. Which coding practice should be used when constructing database queries?

Medium
78

A CI/CD pipeline includes stages for code commit, build, unit test, integration test, staging deploy, and production deploy. Which change would best prevent a faulty build from reaching production?

Medium
79

A developer is writing a CI/CD pipeline using Jenkins Declarative Pipeline. They want to ensure that sensitive credentials (e.g., API keys) are never exposed in console logs. Which two security practices should be implemented? (Choose two.)

Hard
80

A developer wants to perform a rolling update of a Kubernetes Deployment. Which command will update the image and initiate the rollout?

Medium
81

A DevOps engineer runs a container using 'docker run -d -p 8080:80 nginx'. The host firewall blocks incoming traffic on port 8080 from external networks but allows from the local host. Which command would allow the engineer to test the container's web server from the same machine?

Medium
82

Which THREE are valid Kubernetes Service types? (Select three.)

Hard
83

A developer runs 'docker run -d -p 8080:80 --name web nginx:alpine'. The container fails to start. Which command is the most appropriate to investigate the issue?

Medium
84

In Docker, which command is used to build an image from a Dockerfile and tag it as 'myapp:v1'?

Easy
85

A docker-compose.yml defines a web service with environment variables. Which key in the service definition should be used to set environment variables?

Medium
86

A developer is deploying a containerized application with Docker Compose. The application requires environment variables for database credentials that should not be hardcoded in the docker-compose.yml file. Which two methods securely provide these credentials? (Choose two.)

Medium
87

Which Docker command is used to view the logs of a running container in real-time?

Medium
88

A developer is writing a web application and wants to prevent SQL injection attacks. Which coding practice should be followed when constructing SQL queries?

Medium
89

Which TWO Kubernetes resources are used to provide configuration data to pods? (Choose TWO.)

Medium
90

A developer creates a Dockerfile with the following content: FROM python:3.9-slim, COPY app.py /app/, RUN pip install flask, EXPOSE 5000, CMD ["python", "/app/app.py"]. When building the image with 'docker build -t myapp .', what is the purpose of the EXPOSE instruction?

Easy
91

A developer wants to create a Docker image that runs a Python application. Which instruction should be placed at the end of the Dockerfile to specify the command that runs when the container starts?

Easy
92

In a CI/CD pipeline using Jenkins, which stage is typically executed immediately after the build stage to ensure code quality before deployment?

Medium
93

A team uses GitHub Actions for CI/CD. Their workflow includes a job that builds a Docker image and pushes it to a private registry. The job needs to authenticate to the registry using secrets stored in GitHub. Which approach is most secure for passing credentials?

Hard
94

A developer runs 'docker-compose up -d' for a multi-service application. What does the '-d' flag do?

Easy
95

In a Docker Compose file, which key is used to define the dependency order between services?

Easy
96

A developer is implementing secure coding practices to prevent SQL injection. Which approach is most effective when building a SQL query with user input?

Hard
97

A Kubernetes Deployment has replicas: 3. The team updates the container image to a new version. The rollout gets stuck because the new pod fails readiness probes. Which kubectl command will display the rollout status and help diagnose the issue?

Hard
98

In a Docker bridge network, two containers can communicate with each other using which identifier by default?

Medium
99

A company is adopting DevSecOps practices. Which THREE practices should be implemented to secure application deployment?

Hard

Frequently asked questions

What does the Application Deployment and Security domain cover on the 200-901 exam?
Application Deployment and Security questions test whether you can apply the concept in context, not just recognise a definition.
How many questions are in this domain?
This page lists all 99 Application Deployment and Security questions in the 200-901 question bank. The actual exam draws from this domain proportionally to its weighting in the official exam blueprint.
What is the best way to practise this domain?
Start with a short focused session (10 questions) to identify gaps, then work through explanations. Repeat with a longer session once the weak areas feel solid.
Can I practise only Application Deployment and Security questions?
Yes — the session launcher on this page filters questions to this domain only. Choose any session length for inline explanations and scoring.
cisco-devnet-associate CISCO-DEVNET-ASSOCIATE devnet app deployment Practice Questions