Browse all practice questions for the Red Hat Openshift Developer EX288 Practice Exam. Search by topic, open any question and review its full explanation, then test yourself in the practice quiz.

Red Hat Openshift Developer EX288 Practice Exam course image
More practice questions

These questions are part of the practice quiz. Start practicing

  • What are best practices for handling credentials in OpenShift?
  • Which command copies a local image to quay.io/test/myimage:1 with TLS verification disabled?
  • Which directory holds environment-specific customizations for an app named myapp in the recommended structure?
  • How do you define an overlay file for a deployment to override the replica count to 5?
  • Which snippet correctly declares a MySQL dependency on version 5.6 from the MySQL charts repository in chart.yaml?
  • Which steps help ensure a container runs as a non-root user in OpenShift?
  • Explain the difference between an emptyDir volume and a PersistentVolumeClaim.
  • Which command forwards traffic from your local machine to a Pod port in OpenShift?
  • View the rollout history for a deployment config php.
  • Which S2I script is used to save build artifacts?
  • Which command demonstrates removing a config trigger from a deployment config?
  • Which command uses a template dev/lampstack and sets PORT=8080 for an app named myjava without specifying namespace?
  • How can you roll back a failed deployment in OpenShift?
  • What are typical values for readiness and liveness probe configurations, and how do you determine them?
  • Which steps define a simple OpenShift Pipeline (Tekton) to build and deploy on push?
  • Name the core Tekton resources used in OpenShift Pipelines and briefly describe each.
  • Add an environment variable to a deployment myapp from a config map cm1?
  • How do you configure DNS for a Route host and ensure external users can reach the Route?
  • Which statement compares S2I BuildConfigs and Dockerfile-based BuildConfigs in OpenShift?
  • Which resource enforces minimum and maximum resource requests and limits on a per-pod or per-container basis within a namespace?
  • In the image change trigger example, which resource is targeted for the trigger update?
  • Which statement about values.yaml is true?
  • How can you mount a Secret as files inside a container?
  • Which command exposes a service named mysvc?
  • Which approach is recommended to roll out updates to a Pod-based application with minimal downtime?
  • In a Helm chart, how would you define a dependency on mysql version 5.6 from the repository https://mysql.helm.com/charts?
  • What is required to persist a database's data across restarts in OpenShift?
  • How do labels and selectors connect between Services, Pods, and Deployments in OpenShift?
  • What is the purpose of oc new-app, and how does it help speed up application creation in OpenShift?
  • In a container file, how do you set permissions on /app so its readable?
  • What is the role of a Webhook trigger in a BuildConfig?
  • What components are typically generated by oc new-app when creating an application from templates?
  • How do you call the s2i run script located at /usr/libexec/s2i/run from a custom run script?
  • Which statement correctly describes how to enable a private registry pull for pods in a project?
  • Which statement best describes the purpose of values.yaml in a Helm chart?
  • What is the approach for implementing a blue-green deployment pattern in OpenShift using Routes and separate deployments?
  • How do you ensure a Build or Deployment uses a specific ServiceAccount?
  • How do ConfigMaps and Secrets differ, and how can they be consumed by a Pod?
  • What is the purpose of the Downward API in Kubernetes/OpenShift?
  • What is an ImageStream in OpenShift and what is its purpose?
  • Which resource type stores non-sensitive configuration data that can be consumed as environment variables?
  • What is the purpose of an ImageStreamTag, and how does a deployment react to updates to the tag?
  • To rebuild an image for a build config named phpbuild, which OpenShift CLI command should you run?
  • To trigger a new build for the build config named phpbuild, which command should you use?
  • Using the OpenShift CLI, which command would you use to set a readiness probe on a deployment named phpapp with port 8080 and the /healthz endpoint, checking every 30 seconds?
  • Which resource references a StorageClass to provision storage for a pod, and what does the StorageClass define?
  • Which resource kind is used in the example to override the replica count for an overlay deployment?
  • In a Helm chart example, which file would you typically edit to set the container port for the deployed pod?
  • How do you access OpenShift’s logging and metrics for your application?
  • Which command updates the image change trigger for the deployment config php to use the image phpns/myphp:latest for the container phpapp in namespace phpns?
  • What is the purpose of ResourceQuota and LimitRange in OpenShift, and how do they affect resource usage in a project?
  • When would you use emptyDir versus a PersistentVolumeClaim in a pod, and what are their lifecycles?
  • How do you create a secret named mysecret with password=secretpassword?
  • Compare Deployment and StatefulSet in OpenShift: when would you choose each?
  • How do maxSurge and maxUnavailable influence rolling updates in a Deployment?
  • Rollback to version 2 of deployment config php.
  • In the set volume command, what is the container path where the config map is mounted?
  • Which OpenShift CLI command shows the current project context when run without arguments?
  • Which command removes the config trigger from the deployment config mysql?
  • In the command oc set env buildconfig/phpbuild BUILD_LOGLEVEL=4, what resource type is being configured?
  • How would you configure a BuildConfig to respond to Git webhook events and automatically start builds?
  • How can you inject environment variables into a container from a Secret?
  • Which sequence describes a typical end-to-end deployment flow for a simple OpenShift app from source to exposure to users?
  • What is the primary purpose of a Readiness Probe in OpenShift?
  • In Kubernetes/OpenShift, which statement correctly describes Pod and Deployment?
  • What is an OpenShift project and how does it relate to Kubernetes namespaces?
  • After processing a Template with oc process, which command can you use to create the resources described by the output?
  • The .s2i/bin directory in a source tree contains what?
  • Which command creates a template from the file template.json?
  • How can you view logs for a specific container in a multi-container Pod?
  • Which deployment strategy is designed to minimize downtime during updates by controlling the number of pods upgraded at a time?
  • How would you implement a simple healthcheck endpoint for a microservice to be used by liveness/readiness probes?
  • What is the purpose of an ImageStream in OpenShift, and how does it relate to external images?
  • In the image change trigger example, which container name is specified?
  • Which command starts a build for a specific buildconfig named myjava?
  • How can you enable horizontal pod autoscaling in OpenShift, and what metrics does it use by default?
  • In a Kubernetes Deployment, which field controls the number of desired pod replicas?
  • Which method would you use to promote a built image from development to production within the same OpenShift cluster?
  • What is the Security Context Constraint (SCC) in OpenShift, and why might you adjust it?
  • Which command would create a service representing an external host named customerdb.oracle.com?
  • Which command grants the system:image-puller role to system:serviceaccount:myphp in the otherphp namespace?
  • What is a BuildConfig used for in OpenShift?
  • Which command would you use to list the Route resources in the cluster?
  • What is the purpose of a Kubernetes namespace versus an OpenShift project, and how does RBAC differ?
  • What is the exact image reference used in the image change trigger example?
  • What is an ImageStreamTag and how does it support automatic image updates?
  • What is the role of a Deployment in OpenShift, and how does it relate to ReplicaSets?
  • Which command includes the -c flag to specify the container name in the image change trigger example?
  • What does a Route do in OpenShift?
  • Where can you access logs for a particular pod, and what does oc logs show?
  • In kustomize, where do you define the files to be built for a customization?
  • How would you verify that a newly created Route is correctly exposing your application?
  • What is the purpose of a Service in OpenShift?
  • Which command creates a Docker registry secret named quayio for the server quay.io with user1 and pw123?
  • Which statement describes the role of chart.yaml?
  • In a Helm chart, which file do you edit to define dependencies for subcharts?
  • Which command would move an image tag between image streams?
  • Which of the following triggers redeployments when the image tag updates?
  • Where do readiness probes go in a deployment spec?
  • What is the name of the overlay file referenced to change the replica count in the example?
  • What is the purpose of SecurityContextConstraints in OpenShift?
  • How is a ServiceAccount's API token made available to applications inside a pod, and how can an application use it?
  • Which command imports an external container image into an OpenShift ImageStream by specifying the image location and confirming the import?
  • Which OpenShift CLI command switches to a different project?
  • How can Helm charts be used in OpenShift, and what OpenShift feature supports Helm templates?
  • Where do liveness probes go in a deployment spec?
  • Which command would you use to view the fields and descriptions of a resource in OpenShift, aiding YAML authoring?
  • How can automatic builds be configured when code is pushed to Git in OpenShift?
  • What is the docker username used in the quayio secret creation?
  • Which command creates a service of type ExternalName mapping to the host customerdb.oracle.com?
  • Which command creates a template from a local file to create a template object?
  • What does the oc set image command do and how can it trigger a rollout?
  • Which command verifies the current OpenShift project you are in after switching?
  • What does the oc tag command do in OpenShift?
  • True or False: An ExternalName service represents an external host.
  • What is a rolling update, and how does OpenShift perform upgrades without downtime?
  • How do you update an existing Deployment to use a new image tag?
  • Which feature allows an ImageStream to automatically update its tag from an external image source?
  • In RBAC, which resources are most appropriate to grant namespace-scoped permissions to create pods?
  • In the set volume command, what is the resource type specified with -t?
  • To grant a service account permission to create pods in a specific namespace using RBAC, which steps are correct?
  • Podman registry credentials are stored in which file path on the host file system for a typical user session?
  • Which statement best describes NetworkPolicy in OpenShift and how it affects pod traffic?
  • How can you restrict a pod from using more than a specified amount of CPU or memory?
  • Which mechanism enables safely updating applications to new image versions while retaining rollback capability?
  • Which OpenShift object is used to group related resources with parameters, enabling reuse?
  • How does a Route work in OpenShift, and what TLS termination options are available?
  • When a PersistentVolumeClaim references a StorageClass, what is created and who provisions it?
  • What is the difference between DeploymentConfig and Deployment in OpenShift, and when would you use each?
  • Start rolling out a new change to a deployment config named php.
  • Which command starts a build for an application?
  • How do you expose a Pod port to a Service in OpenShift?
  • Which s2i command tests a local build using the image phpbuild:latest with source in the ./app and tags it as php:1?
  • Which command creates an app named myjava from template dev/lampstack in namespace dev with PORT=8080?
  • Which command configures a buildconfig to trigger when the base image changes?
  • What is the purpose of labels in a Service?
  • Which Helm command creates a new chart named myphp?
  • When configuring TLS for an OpenShift Route, which Route field references the TLS secret?
  • How do you create configmap cm1 with value PORT=8080?
  • Which object controls the number of pod replicas for an application in OpenShift?
  • How do you create an OpenShift application named myjava from a git repository at https://mygitrepo using the context directory java?
  • Which Helm command installs a chart from the local directory into the cluster?
  • An OpenShift Template is a collection of objects with parameters. How do you substitute parameters and create resources from it?
  • How do you specify resource requests and limits for a container in OpenShift?
  • Which command checks the status of a deployment rollout progress in OpenShift?
  • How can you access application logs centrally in OpenShift, and what content do the logs typically show?
  • Which command configures the build config phpbuild to trigger whenever the base image newapp/php:1 changes?
  • How do you create configmap cm2 for the file /tmp/values.txt?
  • In a Helm template for a pod, how do you add an array of environment variables from a values.yaml array named env?
  • How do you associate a TLS certificate with an OpenShift Route to enable HTTPS?
  • How do you view logs for a specific pod in OpenShift?
  • ImageStreams in OpenShift provide which capability?
  • How do you create a new OpenShift project and switch to it?
  • In the image change trigger example, which namespace is specified?
  • Where in the application source code do you place S2I scripts to override the build process?
  • When would you use a DeploymentConfig versus a Deployment in OpenShift?
  • When mounting a ConfigMap as a volume, how can you access individual keys as separate files inside the container?
  • Which OpenShift object is responsible for managing the rollout of Pods and tracking their versions?
  • How do you grant a user permissions to manage resources within a project using RBAC?
  • How do you create a secret from literal values using the CLI?
  • Which command creates an app named phpapp from the image stream myphp in the shared namespace?
  • If you want to access a database service in OpenShift from an application, which approach is recommended?
  • What is the command to create a configmap cm3 with the literal value DB_HOST=localhost?
  • Which command creates a new Helm chart skeleton named myphp?
  • Which command lists all image stream names in the openshift namespace?
  • Which approaches can provide environment variables to a pod from both a Secret and a ConfigMap?
  • How does an OpenShift Route expose a service externally and what is the role of the Route host?
  • How would you temporarily access a running container to investigate an issue (interactive shell) in OpenShift?
  • How would you mount a ConfigMap as a volume in a Pod?
  • Which command creates an image stream myphp:1.0 by importing from quay.io/test/myphp:latest with --confirm?
  • What is a PodDisruptionBudget (PDB), and when would you create one?
  • Which OpenShift resource is primarily used to expose an application to external traffic with a stable hostname?
  • Which TLS termination options are supported for an OpenShift Route?
  • Explain how a PersistentVolumeClaim provides storage to a Pod.
  • What steps would you take to diagnose a BuildConfig build that fails with a compilation error?
  • How do you set the environment variable BUILD_LOGLEVEL to 4 in the build config named phpbuild?
  • Which method can be used to inject secrets into a container's environment?
  • How do you rollback a deployment to the previous revision in OpenShift?
  • What is image promotion in OpenShift, and how do you move an image between streams?
  • When deciding between a Source-to-Image (S2I) builder and a custom builder image in OpenShift BuildConfig, which is correct?
  • Which command would you use to inspect logs for a BuildConfig build?
  • Add an environment variable to a deployment myapp from a secret mysecret?
  • What is the primary purpose of an ImageStream in OpenShift, and how is it used by a Deployment?
  • How do you customize the service account used by a deployment, and why would you do so?
  • How does the Downward API expose pod metadata to containers?
  • In an overlay kustomization.yaml, how do you refer to an overlay file called replica_count.yaml?
  • Which statement is true about oc rollout undo in OpenShift?
  • Which command retrieves the tags for all inbuilt PHP image streams in OpenShift?
  • Which command uses the plural form 'triggers' to modify a deployment config?
  • What is the purpose of a Route in OpenShift?
  • Which command deletes a build named phpbuild-2?
  • What is the purpose of the oc apply -f command?
  • Which Tekton resource represents the execution of a Pipeline, enabling traceability of a specific run?
  • What are the names of the S2I scripts used to modify a S2I build?
  • Which command links the secret quayio to the default service account for pulling images?
  • How do you pause and resume a Deployment rollout in OpenShift?
  • Which command mounts config map cm1 as volume myvol into /tmp/config in deployment myapp?
  • Mounting a Secret as a volume results in secret data being available to the container in which form?
  • What does the abbreviation 'dc' stand for in OpenShift CLI?
  • How do you configure TLS termination for an OpenShift Route when you have a certificate and private key?
  • Which command adds an environment variable to deployment myapp from a secret named mysecret?
  • Which command links the secret quayio to the builder service account so S2I can use it?
  • How can you locate the S2I scripts location in an existing S2I builder image?
  • What is a ServiceAccount, and how do pods use it?
  • What are best practices for packaging and deploying a small Node.js application on OpenShift using BuildConfig, ImageStream, Deployment, and Route?
  • Which OpenShift resource provides TLS termination and external hostname exposure for an application?
  • How can you ensure your application can access a database service running in OpenShift?
  • What is the purpose of a Security Context Constraint (SCC) in OpenShift?
  • What is the purpose of a Service in OpenShift, and how does it enable pod communication?
  • Which command configures a post-commit hook on the build config phptest to run bundle exec rake test --verbose?
  • What is the docker registry server specified when creating the quayio secret?
  • Which of the following is typically governed by an OpenShift SecurityContextConstraints?
  • What is the recommended directory structure for an application named myapp in a kustomize project?
  • How can you rotate a secret in OpenShift without causing downtime for apps using it?
  • How do you view all resources in the current project with details?
  • In the image change trigger example, which flag is used to specify the container?
  • In a Helm template, how do you refer to the image.port parameter?
  • In Tekton, which component executes the defined Tasks to perform the build and deploy steps?
  • How do you run a locally built s2i image named php:1 for testing?
  • What is the purpose of the patches section in an overlay kustomization.yaml?
  • How can you expose a service externally using Route?
  • Which command stops a currently running build named phpbuild-2?
Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy