JOBSEEKER?

Kubernetes Interview Questions

Practice for Kubernetes interviews by solving TestDome questions. Our interview questions are used by more than 7,000 companies and 450,000 individual test takers.

Jobseekers: Certify Your Knowledge

Take a Certification Test

Companies: Use Our Tests for Screening

Buy a Pack Of Candidates

Need to practice your Kubernetes skills for an upcoming job interview? Try solving these Kubernetes interview questions that test knowledge of Kubernetes concepts such as services, deployments, and ingress. We’ll provide feedback on your answers, and you can use a hint if you get stuck.

These Kubernetes questions are examples of real tasks used by employers to screen job candidates such as DevOps developers, engineers, and others that require knowledge of Kubernetes.

1. File Ingress

Ingress
   
Easy 

Consider the following Ingress controller:

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: main-ingress
spec:
  rules:
  - http:
      paths:
      - path: /
        pathType: Prefix
        backend:
          serviceName: main-app
          servicePort: 80
      - path: /files/
        pathType: Prefix
        backend:
          serviceName: file-app
          servicePort: 80
      - path: /files/default.png
        pathType: Exact
        backend:
          serviceName: default-app
          servicePort: 8080

Select all the true statements.

(Select all acceptable answers.)

Requests to /files/banner.jpg will be served by the file-app service.
Requests to /files_old/banner.jpg will be served by the file-app service.
The main-app service has to be declared with "name: main-app" metadata.
Requests to /files/default.png will be served by the default-app service.
Only requests that target port 8080 and match the path will be forwarded to the default-app service.
   


2. Nginx Deployment

Deployment Services
   
Easy 

The team responsible for Kubernetes wants to add a Deployment that will deploy 4 nginx Pods which should have port 443 open. Finish the following YAML configuration so that it implements those requirements:

apiVersion: apps/v1
kind: 
metadata:
  name: deployment-nginx
  labels:
    web: public
spec:
  replicas: 
  selector:
    matchLabels:
      web: public
  template:
    metadata:
      labels:
        : 
    spec:
      containers:
      - name: nginx
        image: nginx:1.14.2
        ports:
        - : 443
   


If you feel ready, take one of our timed public Kubernetes Interview Questions tests:
Kubernetes

Kubernetes Online Test (Easy)

DevOps

Kubernetes and DevOps Online Test (Easy)

Not exactly what you are looking for? Go to our For Jobseekers section.
Dashboard Start Trial Sign In Home Tour Tests Questions Pricing For Jobseekers