Kubernetes Fundamentals Flashcards

1
Q

What are Kubernetes Resources?

A

Resources are simply Objects of a certain type (ex. Pods, Services, Deployments, etc.) in the K8s API. You interact with the Cluster by creating and modifying these K8s Objects

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is a Kubernetes Pod?

A

The most basic resource in K8s, represents a group of one or more containers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a Kubernetes Service?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is a Kubernetes Deployment?

A

Provides a way to declaratively update Pods and ReplicaSets, great for scaling stateless apps and uses RollingUpdate by default for zero downtime updates

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the command to list all available resource types within the cluster?

A

$ kubectl api-resources

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How can you get documentation about a certain resources type in K8s?

A

$ kubectl explain

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How can you define your own custom resource types?

A

CustomResourceDefinition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is a ReplicaSet?

A

Ensures a given # of Pods are running at any given time - it’s a copy of a Pod to ensure resiliency

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How do you imperatively create a deployment, what command would you use?

A

$ kubectl create deployment <deploy> --image=<image></image></deploy>

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is a StatefulSet?

A

Similiar to Deployments, but for Stateful Pods, they maintain order and stick identity (same Pod name, networking, hostname, etc.) and it requires a Headless Service to go alongside it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is a DaemonSet?

A

Guarantees that a replica Pod will run on each Node as they join the cluster. You can use filtering to pick and choose which nodes, but good for deploying vendor software (ex. Twistlock)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a Job?

A

A job will reliably run containerized task to completion

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a CronJob?

A

This will create and Run Jobs repeatedly according to a schedule

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is the Control Plane?

A

A set of software components that manage worker Nodes and Pods, it’s not just a server

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are Worker Nodes?

A

Servers that host Pod and run container workloads

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

List all of the Control Plane components

A

API Server, etcd, Scheduler, Controller Manager, and Cloud Controller Manager

17
Q

List all of the Worker Node components

A

kube-proxy, kubelet, Container Runtime,

18
Q

What is the API Server?

A

This is the backbone for all things Kubernetes and is a control plane component. Used to communicate and interact with the Cluter.

19
Q

What is etcd?

A

Reliable Object Storage - a data store for the API Server. API Server stores data about the state of the cluster

20
Q

What is the Scheduler?

A

A CP component that watches for new Pods that haven’t been assigned to a worker node. Selecting a Node for a Pod is called “Scheduling”