Containerization Flashcards

1
Q

What is a Container?

A

A lightweight, standalone, and executable software package that includes everything needed to run a piece of software

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

What is an Image?

A

Container images are lightweight, standalone packages that include all the necessary elements for running software, such as code, dependencies, and system tools. They provide a portable and consistent environment, enabling applications to run reliably across various computing environments.

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

What is a tag?

A

Attached at build time, used for versioning mostly

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

What is “exposing a port” what things are needed?

A

Need to listen for traffic within the container
Need to forward traffic to a pod through the container

-p host-port:container-port

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

What is a project?

A

Logical unit used to organize and isolate resources and applications within a container orchestration environment.

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

What is a Pod?

A

A single instance of a running process. Shared network namespace, shared storage volumes.

oc create <spec>
oc delete pod <pod-name></pod-name></spec>

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

What is a DeploymentConfig?

A

A template for a pod. An object that defines a desired state of a deployment and allows for declarative updates to applications

oc new-app <image> –name <name> –as-deployment-config
oc delete all -l <label></label></name></image>

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

What is the ReplicaController? What does it work with?

A

When a new update is made to the deployment config, a new replication controller is made and the old one is deleted
Actually runs the pods

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

What is a Service?

A
  • Borrowed from Kubernetes
  • Internal IP / DNA to expose a set of Pods
  • Used for intercommunication between different components of an application within a cluster
  • Load Balancing: automatically distribute incoming network traffic across the pods that match the service

oc expose –port <port> pods/<pod></pod></port>

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

What is a Route?

A

Expose a service to the external open internet
Provides a publicly accessible URL

oc expose service/<service></service>

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

What is a ConfigMap?

A

Borrowed from Kubernetes
Holds config data for pods to consume
“Consuming” configmap means using the data within the configmap
Not for sensitive data

oc set env dc/<deploymentConfig> -from cm/<configMap></configMap></deploymentConfig>

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

What are secrets?

A

Openshift type
For private information

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

What is an ImageStream?

A

Blueprint for a container
Correspond to names
Collection of related container images

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

What is an ImageStreamTag?

A

Specific pointer or reference to a tagged image within an image stream
DeploymentConfigs can “subscribe” to an image stream tag
oc tag <original> <destination></destination></original>

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

What are Builds?

A

Taking the source code of an application and creating an image from it

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

What is a BuildConfig? What are Webhooks? What are Build Hooks?

A

oc new-build <source></source>

Webhooks
Endpoints triggered when devs push code, openshift starts build when called

Build Hooks
Do something after a build completes

17
Q

What is S2I?

A

Dockerfile not needed to produce an image
Create an image directly from source code using “builder images”

18
Q

What is HPA (Horizontal Pod Autoscaler)? What information is used?

A

Add replicas to a deployment config
oc scale dc/<deployment> –replicas=3</deployment>

Number of Pods
Current Resource Usage
Desired Resource Usage
oc autoscale dc/<deployment

config> –min 1 –max 1- –cpu-percent=80

19
Q

What are Templates?

A

Pre-configured set of openshift objects that can be used to create multiple instances of applications or services
Define and parameterize a group of resources
Includes services, routes, deployment configs, route, imageStream