day09/40 Flashcards

1
Q

4 types of Services

A

There are 4 types of Services:

ClusterIP(For Internal access)
NodePort(To access the application on a particular port)
LoadBalancer(To access the application on a domain name or IP address without using the port number)
External (To use an external DNS for routing)

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

4 mast fileds in yaml

A

apiVersion:
kind:
metadat:
spec:

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

ERROR: “mapping” in YAML

A

in YAML refers to a key-value pair (e.g., key: value).

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

ERROR: “not allowed in this context”

A

means that the placement of a key-value pair at that specific position within the YAML structure is invalid according to the Kubernetes schema for the resource being defined.

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

What is the problem with dynamic IP addresses for pods in Kubernetes?

A

The IP addresses of pods change when they are restarted, making it difficult for them to communicate with each other and with other services.

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

What is the solution to the problem of dynamic IP addresses for pods?

A

Kubernetes services create a static endpoint (DNS name or IP address) that enables access to pods behind the service.

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

What is the most common type of service in Kubernetes?

A

ClusterIP - a service available only within the Kubernetes cluster.

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

Which type of Kubernetes service exposes the service on a specific port on all nodes?

A

NodePort

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

What is the Target Port?

A

An internal port within the cluster used by services and other pods to access the service.

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

Which type of Kubernetes service creates an external Load Balancer and links it to the service?

A

LoadBalancer

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

Which type of Kubernetes service maps an external DNS name to a Kubernetes service?

A

ExternalName

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

What is the difference between a Kind cluster and a regular Kubernetes cluster?

A

A Kind cluster requires additional configurations to expose external services, unlike a regular Kubernetes cluster.

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

How can you shorten the kubectl command?

A

By setting an alias in the ~/.bash_profile file - for example: alias k=’kubectl’.

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

What are Endpoints in a Kubernetes service?

A

A list of the IP addresses of the pods that the service routes traffic to.

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